@coinflowlabs/react 4.1.0 → 4.1.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.
Files changed (131) hide show
  1. package/README.md +1 -0
  2. package/build/cjs/CoinflowApplePayButton.d.ts +3 -5
  3. package/build/cjs/CoinflowApplePayButton.js +42 -38
  4. package/build/cjs/CoinflowApplePayButton.js.map +1 -1
  5. package/build/cjs/CoinflowCardForm.d.ts +2 -2
  6. package/build/cjs/CoinflowCardForm.js +35 -38
  7. package/build/cjs/CoinflowCardForm.js.map +1 -1
  8. package/build/cjs/CoinflowGooglePayButton.d.ts +1 -1
  9. package/build/cjs/CoinflowIFrame.d.ts +7 -2
  10. package/build/cjs/CoinflowIFrame.js +65 -6
  11. package/build/cjs/CoinflowIFrame.js.map +1 -1
  12. package/build/cjs/CoinflowPurchase.d.ts +2 -3
  13. package/build/cjs/CoinflowPurchase.js +11 -67
  14. package/build/cjs/CoinflowPurchase.js.map +1 -1
  15. package/build/cjs/CoinflowPurchaseHistory.d.ts +2 -2
  16. package/build/cjs/CoinflowPurchaseHistory.js +10 -42
  17. package/build/cjs/CoinflowPurchaseHistory.js.map +1 -1
  18. package/build/cjs/CoinflowPurchaseProtection.d.ts +1 -1
  19. package/build/cjs/CoinflowPurchaseProtection.js +2 -2
  20. package/build/cjs/CoinflowPurchaseProtection.js.map +1 -1
  21. package/build/cjs/CoinflowWithdraw.d.ts +3 -3
  22. package/build/cjs/CoinflowWithdraw.js +11 -45
  23. package/build/cjs/CoinflowWithdraw.js.map +1 -1
  24. package/build/cjs/CoinflowWithdrawHistory.d.ts +2 -2
  25. package/build/cjs/CoinflowWithdrawHistory.js +10 -43
  26. package/build/cjs/CoinflowWithdrawHistory.js.map +1 -1
  27. package/build/cjs/common/CoinflowLibMessageHandlers.d.ts +21 -0
  28. package/build/cjs/common/CoinflowLibMessageHandlers.js +186 -0
  29. package/build/cjs/common/CoinflowLibMessageHandlers.js.map +1 -0
  30. package/build/cjs/{CoinflowTypes.d.ts → common/CoinflowTypes.d.ts} +36 -41
  31. package/build/cjs/{CoinflowTypes.js → common/CoinflowTypes.js} +3 -2
  32. package/build/cjs/common/CoinflowTypes.js.map +1 -0
  33. package/build/cjs/common/CoinflowUtils.d.ts +21 -0
  34. package/build/cjs/{CoinflowUtils.js → common/CoinflowUtils.js} +37 -22
  35. package/build/cjs/common/CoinflowUtils.js.map +1 -0
  36. package/build/cjs/common/SolanaPeerDeps.d.ts +5 -0
  37. package/build/cjs/common/SolanaPeerDeps.js +22 -0
  38. package/build/cjs/common/SolanaPeerDeps.js.map +1 -0
  39. package/build/cjs/common/index.d.ts +3 -0
  40. package/build/cjs/common/index.js +7 -0
  41. package/build/cjs/common/index.js.map +1 -0
  42. package/build/cjs/index.d.ts +1 -3
  43. package/build/cjs/index.js +1 -3
  44. package/build/cjs/index.js.map +1 -1
  45. package/build/esm/CoinflowApplePayButton.d.ts +3 -5
  46. package/build/esm/CoinflowApplePayButton.js +42 -36
  47. package/build/esm/CoinflowApplePayButton.js.map +1 -1
  48. package/build/esm/CoinflowCardForm.d.ts +2 -2
  49. package/build/esm/CoinflowCardForm.js +37 -40
  50. package/build/esm/CoinflowCardForm.js.map +1 -1
  51. package/build/esm/CoinflowGooglePayButton.d.ts +1 -1
  52. package/build/esm/CoinflowIFrame.d.ts +7 -2
  53. package/build/esm/CoinflowIFrame.js +66 -5
  54. package/build/esm/CoinflowIFrame.js.map +1 -1
  55. package/build/esm/CoinflowPurchase.d.ts +2 -3
  56. package/build/esm/CoinflowPurchase.js +10 -65
  57. package/build/esm/CoinflowPurchase.js.map +1 -1
  58. package/build/esm/CoinflowPurchaseHistory.d.ts +2 -2
  59. package/build/esm/CoinflowPurchaseHistory.js +10 -42
  60. package/build/esm/CoinflowPurchaseHistory.js.map +1 -1
  61. package/build/esm/CoinflowPurchaseProtection.d.ts +1 -1
  62. package/build/esm/CoinflowPurchaseProtection.js +1 -1
  63. package/build/esm/CoinflowPurchaseProtection.js.map +1 -1
  64. package/build/esm/CoinflowWithdraw.d.ts +3 -3
  65. package/build/esm/CoinflowWithdraw.js +11 -45
  66. package/build/esm/CoinflowWithdraw.js.map +1 -1
  67. package/build/esm/CoinflowWithdrawHistory.d.ts +2 -2
  68. package/build/esm/CoinflowWithdrawHistory.js +10 -43
  69. package/build/esm/CoinflowWithdrawHistory.js.map +1 -1
  70. package/build/esm/common/CoinflowLibMessageHandlers.d.ts +21 -0
  71. package/build/esm/common/CoinflowLibMessageHandlers.js +180 -0
  72. package/build/esm/common/CoinflowLibMessageHandlers.js.map +1 -0
  73. package/build/esm/{CoinflowTypes.d.ts → common/CoinflowTypes.d.ts} +36 -41
  74. package/build/esm/{CoinflowTypes.js → common/CoinflowTypes.js} +2 -3
  75. package/build/esm/common/CoinflowTypes.js.map +1 -0
  76. package/build/esm/common/CoinflowUtils.d.ts +21 -0
  77. package/build/esm/{CoinflowUtils.js → common/CoinflowUtils.js} +37 -22
  78. package/build/esm/common/CoinflowUtils.js.map +1 -0
  79. package/build/esm/common/SolanaPeerDeps.d.ts +5 -0
  80. package/build/esm/common/SolanaPeerDeps.js +17 -0
  81. package/build/esm/common/SolanaPeerDeps.js.map +1 -0
  82. package/build/esm/common/index.d.ts +3 -0
  83. package/build/esm/common/index.js +4 -0
  84. package/build/esm/common/index.js.map +1 -0
  85. package/build/esm/index.d.ts +1 -3
  86. package/build/esm/index.js +1 -3
  87. package/build/esm/index.js.map +1 -1
  88. package/build/tsconfig.tsbuildinfo +1 -1
  89. package/package.json +16 -10
  90. package/build/cjs/CoinflowTypes.js.map +0 -1
  91. package/build/cjs/CoinflowUtils.d.ts +0 -22
  92. package/build/cjs/CoinflowUtils.js.map +0 -1
  93. package/build/cjs/useHandleHeightChange.d.ts +0 -2
  94. package/build/cjs/useHandleHeightChange.js +0 -24
  95. package/build/cjs/useHandleHeightChange.js.map +0 -1
  96. package/build/cjs/wallet/EthIFrameMessageHandlers.d.ts +0 -5
  97. package/build/cjs/wallet/EthIFrameMessageHandlers.js +0 -42
  98. package/build/cjs/wallet/EthIFrameMessageHandlers.js.map +0 -1
  99. package/build/cjs/wallet/NearIFrameMessageHandlers.d.ts +0 -5
  100. package/build/cjs/wallet/NearIFrameMessageHandlers.js +0 -31
  101. package/build/cjs/wallet/NearIFrameMessageHandlers.js.map +0 -1
  102. package/build/cjs/wallet/SocketService.d.ts +0 -5
  103. package/build/cjs/wallet/SocketService.js +0 -43
  104. package/build/cjs/wallet/SocketService.js.map +0 -1
  105. package/build/cjs/wallet/SolanaIFrameMessageHandlers.d.ts +0 -19
  106. package/build/cjs/wallet/SolanaIFrameMessageHandlers.js +0 -132
  107. package/build/cjs/wallet/SolanaIFrameMessageHandlers.js.map +0 -1
  108. package/build/cjs/wallet/useIframeWallet.d.ts +0 -15
  109. package/build/cjs/wallet/useIframeWallet.js +0 -137
  110. package/build/cjs/wallet/useIframeWallet.js.map +0 -1
  111. package/build/esm/CoinflowTypes.js.map +0 -1
  112. package/build/esm/CoinflowUtils.d.ts +0 -22
  113. package/build/esm/CoinflowUtils.js.map +0 -1
  114. package/build/esm/useHandleHeightChange.d.ts +0 -2
  115. package/build/esm/useHandleHeightChange.js +0 -19
  116. package/build/esm/useHandleHeightChange.js.map +0 -1
  117. package/build/esm/wallet/EthIFrameMessageHandlers.d.ts +0 -5
  118. package/build/esm/wallet/EthIFrameMessageHandlers.js +0 -38
  119. package/build/esm/wallet/EthIFrameMessageHandlers.js.map +0 -1
  120. package/build/esm/wallet/NearIFrameMessageHandlers.d.ts +0 -5
  121. package/build/esm/wallet/NearIFrameMessageHandlers.js +0 -27
  122. package/build/esm/wallet/NearIFrameMessageHandlers.js.map +0 -1
  123. package/build/esm/wallet/SocketService.d.ts +0 -5
  124. package/build/esm/wallet/SocketService.js +0 -35
  125. package/build/esm/wallet/SocketService.js.map +0 -1
  126. package/build/esm/wallet/SolanaIFrameMessageHandlers.d.ts +0 -19
  127. package/build/esm/wallet/SolanaIFrameMessageHandlers.js +0 -128
  128. package/build/esm/wallet/SolanaIFrameMessageHandlers.js.map +0 -1
  129. package/build/esm/wallet/useIframeWallet.d.ts +0 -15
  130. package/build/esm/wallet/useIframeWallet.js +0 -131
  131. package/build/esm/wallet/useIframeWallet.js.map +0 -1
@@ -1,19 +1,15 @@
1
- /// <reference types="react" />
2
- import type { Connection, VersionedTransaction } from '@solana/web3.js';
3
- import { PublicKey, Signer, Transaction } from '@solana/web3.js';
4
- import { WalletContextState } from '@solana/wallet-adapter-react';
5
- import { Wallet } from '@near-wallet-selector/core';
6
- declare enum SettlementType {
1
+ import type { Connection, VersionedTransaction, PublicKey, Signer, Transaction } from '@solana/web3.js';
2
+ export declare enum SettlementType {
7
3
  Credits = "Credits",
8
4
  USDC = "USDC",
9
5
  Bank = "Bank"
10
6
  }
11
- declare enum MerchantStyle {
7
+ export declare enum MerchantStyle {
12
8
  Rounded = "rounded",
13
9
  Sharp = "sharp",
14
10
  Pill = "pill"
15
11
  }
16
- type MerchantTheme = {
12
+ export type MerchantTheme = {
17
13
  primary?: string;
18
14
  background?: string;
19
15
  backgroundAccent?: string;
@@ -24,7 +20,7 @@ type MerchantTheme = {
24
20
  font?: string;
25
21
  style?: MerchantStyle;
26
22
  };
27
- interface CustomerInfo {
23
+ export interface CustomerInfo {
28
24
  name?: string;
29
25
  verificationId?: string;
30
26
  displayName?: string;
@@ -46,16 +42,25 @@ export interface CoinflowTypes {
46
42
  loaderBackground?: string;
47
43
  blockchain: CoinflowBlockchain;
48
44
  handleHeightChange?: (height: string) => void;
49
- useSocket?: boolean;
50
45
  theme?: MerchantTheme;
51
46
  }
52
47
  export type PartialBy<T, K extends keyof T> = Omit<T, K> & Partial<Pick<T, K>>;
53
48
  export type OnSuccessMethod = (params: string) => void | Promise<void>;
54
49
  /** Wallets **/
55
- export type SolanaWallet = PartialBy<Pick<WalletContextState, 'wallet' | 'signTransaction' | 'publicKey' | 'sendTransaction' | 'signMessage'>, 'wallet' | 'signTransaction'>;
56
- export type NearWallet = {
50
+ export interface SolanaWallet {
51
+ publicKey: PublicKey | null;
52
+ signTransaction?: <T extends Transaction | VersionedTransaction>(transaction: T) => Promise<T>;
53
+ sendTransaction: <T extends Transaction | VersionedTransaction>(transaction: T) => Promise<string>;
54
+ signMessage?: (message: Uint8Array) => Promise<Uint8Array>;
55
+ }
56
+ export interface NearWallet {
57
57
  accountId: string;
58
- } & Pick<Wallet, 'signAndSendTransaction'>;
58
+ signAndSendTransaction: (transaction: unknown) => Promise<{
59
+ transaction: {
60
+ hash: string;
61
+ };
62
+ }>;
63
+ }
59
64
  type AccessList = Array<{
60
65
  address: string;
61
66
  storageKeys: Array<string>;
@@ -106,33 +111,6 @@ export interface CoinflowBaseHistoryProps extends CoinflowEvmHistoryProps {
106
111
  blockchain: 'base';
107
112
  }
108
113
  export type CoinflowHistoryProps = CoinflowSolanaHistoryProps | CoinflowNearHistoryProps | CoinflowPolygonHistoryProps | CoinflowEthHistoryProps | CoinflowBaseHistoryProps;
109
- export interface CoinflowIFrameProps extends Omit<CoinflowTypes, 'merchantId'>, Pick<CoinflowCommonPurchaseProps, 'chargebackProtectionData' | 'webhookInfo' | 'amount' | 'customerInfo' | 'settlementType'>, Pick<CoinflowCommonWithdrawProps, 'bankAccountLinkRedirect' | 'additionalWallets' | 'transactionSigner' | 'lockAmount'>, Pick<CoinflowEvmPurchaseProps, 'authOnly'> {
110
- walletPubkey: string;
111
- IFrameRef: React.RefObject<HTMLIFrameElement>;
112
- route: string;
113
- routePrefix?: string;
114
- transaction?: string;
115
- token?: string | PublicKey;
116
- tokens?: string[] | PublicKey[];
117
- lockDefaultToken?: boolean;
118
- email?: string;
119
- supportsVersionedTransactions?: boolean;
120
- nearDeposit?: string;
121
- merchantCss?: string;
122
- color?: 'white' | 'black';
123
- rent?: {
124
- lamports: string | number;
125
- };
126
- nativeSolToConvert?: {
127
- lamports: string | number;
128
- };
129
- planCode?: string;
130
- disableApplePay?: boolean;
131
- disableGooglePay?: boolean;
132
- settlementType?: SettlementType;
133
- theme?: MerchantTheme;
134
- usePermit?: boolean;
135
- }
136
114
  /** Transactions **/
137
115
  export type NearFtTransferCallAction = {
138
116
  methodName: 'ft_transfer_call';
@@ -168,7 +146,7 @@ export interface ChargebackProtectionItem {
168
146
  };
169
147
  }
170
148
  export interface CoinflowCommonPurchaseProps extends CoinflowTypes {
171
- amount?: number;
149
+ amount?: number | string;
172
150
  onSuccess?: OnSuccessMethod;
173
151
  webhookInfo?: object;
174
152
  email?: string;
@@ -179,6 +157,8 @@ export interface CoinflowCommonPurchaseProps extends CoinflowTypes {
179
157
  customerInfo?: CustomerInfo;
180
158
  settlementType?: SettlementType;
181
159
  authOnly?: boolean;
160
+ deviceId?: string;
161
+ jwtToken?: string;
182
162
  }
183
163
  export interface CoinflowSolanaPurchaseProps extends CoinflowCommonPurchaseProps {
184
164
  wallet: SolanaWallet;
@@ -289,4 +269,19 @@ export interface ReservoirRedeem extends CommonEvmRedeem {
289
269
  items: ReservoirItems;
290
270
  }
291
271
  export type EvmTransactionData = SafeMintRedeem | ReturnedTokenIdRedeem | ReservoirRedeem | KnownTokenIdRedeem | NormalRedeem;
272
+ export interface CoinflowIFrameProps extends Omit<CoinflowTypes, 'merchantId'>, Pick<CoinflowCommonPurchaseProps, 'chargebackProtectionData' | 'webhookInfo' | 'amount' | 'customerInfo' | 'settlementType' | 'email' | 'planCode' | 'deviceId' | 'jwtToken'>, Pick<CoinflowCommonWithdrawProps, 'bankAccountLinkRedirect' | 'additionalWallets' | 'transactionSigner' | 'lockAmount' | 'lockDefaultToken'>, Pick<CoinflowEvmPurchaseProps, 'authOnly'>, Pick<CoinflowSolanaPurchaseProps, 'rent' | 'nativeSolToConvert' | 'token'> {
273
+ walletPubkey: string | null | undefined;
274
+ route: string;
275
+ routePrefix?: string;
276
+ transaction?: string;
277
+ tokens?: string[] | PublicKey[];
278
+ supportsVersionedTransactions?: boolean;
279
+ nearDeposit?: string;
280
+ merchantCss?: string;
281
+ color?: 'white' | 'black';
282
+ disableApplePay?: boolean;
283
+ disableGooglePay?: boolean;
284
+ theme?: MerchantTheme;
285
+ usePermit?: boolean;
286
+ }
292
287
  export {};
@@ -1,14 +1,13 @@
1
- var SettlementType;
1
+ export var SettlementType;
2
2
  (function (SettlementType) {
3
3
  SettlementType["Credits"] = "Credits";
4
4
  SettlementType["USDC"] = "USDC";
5
5
  SettlementType["Bank"] = "Bank";
6
6
  })(SettlementType || (SettlementType = {}));
7
- var MerchantStyle;
7
+ export var MerchantStyle;
8
8
  (function (MerchantStyle) {
9
9
  MerchantStyle["Rounded"] = "rounded";
10
10
  MerchantStyle["Sharp"] = "sharp";
11
11
  MerchantStyle["Pill"] = "pill";
12
12
  })(MerchantStyle || (MerchantStyle = {}));
13
- export {};
14
13
  //# sourceMappingURL=CoinflowTypes.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CoinflowTypes.js","sourceRoot":"","sources":["../../../src/common/CoinflowTypes.ts"],"names":[],"mappings":"AAQA,MAAM,CAAN,IAAY,cAIX;AAJD,WAAY,cAAc;IACxB,qCAAmB,CAAA;IACnB,+BAAa,CAAA;IACb,+BAAa,CAAA;AACf,CAAC,EAJW,cAAc,KAAd,cAAc,QAIzB;AAED,MAAM,CAAN,IAAY,aAIX;AAJD,WAAY,aAAa;IACvB,oCAAmB,CAAA;IACnB,gCAAe,CAAA;IACf,8BAAa,CAAA;AACf,CAAC,EAJW,aAAa,KAAb,aAAa,QAIxB"}
@@ -0,0 +1,21 @@
1
+ import { CoinflowBlockchain, CoinflowEnvs, CoinflowIFrameProps, CoinflowPurchaseProps } from './CoinflowTypes';
2
+ export declare class CoinflowUtils {
3
+ env: CoinflowEnvs;
4
+ url: string;
5
+ constructor(env?: CoinflowEnvs);
6
+ getNSurePartnerId(merchantId: string): Promise<string | undefined>;
7
+ getCreditBalance(publicKey: string, merchantId: string, blockchain: 'solana' | 'near'): Promise<{
8
+ cents: number;
9
+ }>;
10
+ static getCoinflowBaseUrl(env?: CoinflowEnvs): string;
11
+ static getCoinflowApiUrl(env?: CoinflowEnvs): string;
12
+ static getCoinflowUrl({ walletPubkey, route, routePrefix, env, amount, transaction, blockchain, supportsVersionedTransactions, webhookInfo, email, loaderBackground, handleHeightChange, bankAccountLinkRedirect, additionalWallets, nearDeposit, chargebackProtectionData, merchantCss, color, rent, lockDefaultToken, token, tokens, planCode, disableApplePay, disableGooglePay, customerInfo, settlementType, lockAmount, nativeSolToConvert, theme, usePermit, transactionSigner, authOnly, deviceId, jwtToken, }: CoinflowIFrameProps): string;
13
+ static getTransaction(props: CoinflowPurchaseProps): string | undefined;
14
+ static byBlockchain<T>(blockchain: CoinflowBlockchain, args: {
15
+ solana: T;
16
+ near: T;
17
+ eth?: T;
18
+ polygon: T;
19
+ base: T;
20
+ }): T;
21
+ }
@@ -1,5 +1,5 @@
1
1
  import { __awaiter, __generator } from "tslib";
2
- import base58 from 'bs58';
2
+ import { web3, base58 } from './SolanaPeerDeps';
3
3
  var CoinflowUtils = /** @class */ (function () {
4
4
  function CoinflowUtils(env) {
5
5
  this.env = env !== null && env !== void 0 ? env : 'prod';
@@ -61,7 +61,7 @@ var CoinflowUtils = /** @class */ (function () {
61
61
  };
62
62
  CoinflowUtils.getCoinflowUrl = function (_a) {
63
63
  var _b;
64
- var walletPubkey = _a.walletPubkey, route = _a.route, routePrefix = _a.routePrefix, env = _a.env, amount = _a.amount, transaction = _a.transaction, blockchain = _a.blockchain, supportsVersionedTransactions = _a.supportsVersionedTransactions, webhookInfo = _a.webhookInfo, email = _a.email, loaderBackground = _a.loaderBackground, handleHeightChange = _a.handleHeightChange, useSocket = _a.useSocket, bankAccountLinkRedirect = _a.bankAccountLinkRedirect, additionalWallets = _a.additionalWallets, nearDeposit = _a.nearDeposit, chargebackProtectionData = _a.chargebackProtectionData, merchantCss = _a.merchantCss, color = _a.color, rent = _a.rent, lockDefaultToken = _a.lockDefaultToken, token = _a.token, tokens = _a.tokens, planCode = _a.planCode, disableApplePay = _a.disableApplePay, disableGooglePay = _a.disableGooglePay, customerInfo = _a.customerInfo, settlementType = _a.settlementType, lockAmount = _a.lockAmount, nativeSolToConvert = _a.nativeSolToConvert, theme = _a.theme, usePermit = _a.usePermit, transactionSigner = _a.transactionSigner, authOnly = _a.authOnly;
64
+ var walletPubkey = _a.walletPubkey, route = _a.route, routePrefix = _a.routePrefix, env = _a.env, amount = _a.amount, transaction = _a.transaction, blockchain = _a.blockchain, supportsVersionedTransactions = _a.supportsVersionedTransactions, webhookInfo = _a.webhookInfo, email = _a.email, loaderBackground = _a.loaderBackground, handleHeightChange = _a.handleHeightChange, bankAccountLinkRedirect = _a.bankAccountLinkRedirect, additionalWallets = _a.additionalWallets, nearDeposit = _a.nearDeposit, chargebackProtectionData = _a.chargebackProtectionData, merchantCss = _a.merchantCss, color = _a.color, rent = _a.rent, lockDefaultToken = _a.lockDefaultToken, token = _a.token, tokens = _a.tokens, planCode = _a.planCode, disableApplePay = _a.disableApplePay, disableGooglePay = _a.disableGooglePay, customerInfo = _a.customerInfo, settlementType = _a.settlementType, lockAmount = _a.lockAmount, nativeSolToConvert = _a.nativeSolToConvert, theme = _a.theme, usePermit = _a.usePermit, transactionSigner = _a.transactionSigner, authOnly = _a.authOnly, deviceId = _a.deviceId, jwtToken = _a.jwtToken;
65
65
  var prefix = routePrefix
66
66
  ? "/".concat(routePrefix, "/").concat(blockchain)
67
67
  : "/".concat(blockchain);
@@ -100,9 +100,6 @@ var CoinflowUtils = /** @class */ (function () {
100
100
  if (handleHeightChange) {
101
101
  url.searchParams.append('useHeightChange', 'true');
102
102
  }
103
- if (useSocket) {
104
- url.searchParams.append('useSocket', 'true');
105
- }
106
103
  if (bankAccountLinkRedirect) {
107
104
  url.searchParams.append('bankAccountLinkRedirect', bankAccountLinkRedirect);
108
105
  }
@@ -112,11 +109,17 @@ var CoinflowUtils = /** @class */ (function () {
112
109
  url.searchParams.append('nearDeposit', nearDeposit);
113
110
  if (chargebackProtectionData)
114
111
  url.searchParams.append('chargebackProtectionData', JSON.stringify(chargebackProtectionData));
115
- if (typeof window !== 'undefined') {
116
- // @ts-ignore
117
- var deviceId = (_b = window === null || window === void 0 ? void 0 : window.nSureSDK) === null || _b === void 0 ? void 0 : _b.getDeviceId();
118
- if (deviceId)
119
- url.searchParams.append('deviceId', deviceId);
112
+ if (deviceId) {
113
+ url.searchParams.append('deviceId', deviceId);
114
+ }
115
+ else {
116
+ if (typeof window !== 'undefined') {
117
+ // eslint-disable-next-line @typescript-eslint/ban-ts-comment
118
+ // @ts-ignore
119
+ var deviceId_1 = (_b = window === null || window === void 0 ? void 0 : window.nSureSDK) === null || _b === void 0 ? void 0 : _b.getDeviceId();
120
+ if (deviceId_1)
121
+ url.searchParams.append('deviceId', deviceId_1);
122
+ }
120
123
  }
121
124
  if (merchantCss)
122
125
  url.searchParams.append('merchantCss', merchantCss);
@@ -144,20 +147,32 @@ var CoinflowUtils = /** @class */ (function () {
144
147
  url.searchParams.append('transactionSigner', transactionSigner);
145
148
  if (authOnly === true)
146
149
  url.searchParams.append('authOnly', 'true');
150
+ if (jwtToken)
151
+ url.searchParams.append('jwtToken', jwtToken);
147
152
  return url.toString();
148
153
  };
149
- CoinflowUtils.serializeSolanaTransaction = function (transaction) {
150
- if (!transaction)
151
- return undefined;
152
- var serializedTx = transaction.serialize({
153
- requireAllSignatures: false,
154
- verifySignatures: false,
155
- });
156
- return base58.encode(serializedTx);
157
- };
158
- CoinflowUtils.solanaWalletSupportsVersionedTransactions = function (wallet) {
159
- var _a, _b, _c;
160
- return !!((_c = (_b = (_a = wallet.wallet) === null || _a === void 0 ? void 0 : _a.adapter) === null || _b === void 0 ? void 0 : _b.supportedTransactionVersions) === null || _c === void 0 ? void 0 : _c.has(0));
154
+ CoinflowUtils.getTransaction = function (props) {
155
+ if ('transaction' in props && props.transaction !== undefined) {
156
+ var transaction = props.transaction;
157
+ if (web3 && transaction instanceof web3.Transaction) {
158
+ if (!base58)
159
+ throw new Error('bs58 dependency is required for Solana');
160
+ return base58.encode(transaction.serialize({
161
+ requireAllSignatures: false,
162
+ verifySignatures: false,
163
+ }));
164
+ }
165
+ if (web3 && transaction instanceof web3.VersionedTransaction) {
166
+ if (!base58)
167
+ throw new Error('bs58 dependency is required for Solana');
168
+ return base58.encode(transaction.serialize());
169
+ }
170
+ return btoa(JSON.stringify(transaction));
171
+ }
172
+ if ('action' in props && props.action !== undefined) {
173
+ return btoa(JSON.stringify(props.action));
174
+ }
175
+ return undefined;
161
176
  };
162
177
  CoinflowUtils.byBlockchain = function (blockchain, args) {
163
178
  switch (blockchain) {
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CoinflowUtils.js","sourceRoot":"","sources":["../../../src/common/CoinflowUtils.ts"],"names":[],"mappings":";AAMA,OAAO,EAAC,IAAI,EAAE,MAAM,EAAC,MAAM,kBAAkB,CAAC;AAE9C;IAIE,uBAAY,GAAkB;QAC5B,IAAI,CAAC,GAAG,GAAG,GAAG,aAAH,GAAG,cAAH,GAAG,GAAI,MAAM,CAAC;QACzB,IAAI,IAAI,CAAC,GAAG,KAAK,MAAM;YAAE,IAAI,CAAC,GAAG,GAAG,2BAA2B,CAAC;aAC3D,IAAI,IAAI,CAAC,GAAG,KAAK,OAAO;YAAE,IAAI,CAAC,GAAG,GAAG,uBAAuB,CAAC;;YAC7D,IAAI,CAAC,GAAG,GAAG,sBAAe,IAAI,CAAC,GAAG,mBAAgB,CAAC;IAC1D,CAAC;IAEK,yCAAiB,GAAvB,UAAwB,UAAkB;;;gBACxC,sBAAO,KAAK,CAAC,IAAI,CAAC,GAAG,GAAG,yBAAkB,UAAU,CAAE,CAAC;yBACpD,IAAI,CAAC,UAAA,QAAQ,IAAI,OAAA,QAAQ,CAAC,IAAI,EAAE,EAAf,CAAe,CAAC;yBACjC,IAAI,CACH,UAAC,IAGA,YAAK,OAAA,CAAA,MAAA,IAAI,CAAC,aAAa,0CAAE,cAAc,KAAI,IAAI,CAAC,cAAc,CAAA,EAAA,CAChE;yBACA,KAAK,CAAC,UAAA,CAAC;wBACN,OAAO,CAAC,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;IACH,CAAC;IACH,oBAAC;AAAD,CAAC,AArQD,IAqQC"}
@@ -0,0 +1,5 @@
1
+ import * as SolanaWeb3Js from '@solana/web3.js';
2
+ import base58Imported from 'bs58';
3
+ declare const web3: typeof SolanaWeb3Js | undefined;
4
+ declare const base58: typeof base58Imported | undefined;
5
+ export { web3, base58 };
@@ -0,0 +1,17 @@
1
+ // This works in angular, but not react
2
+ // let web3: typeof import('@solana/web3.js') | undefined;
3
+ // let base58: typeof import('bs58') | undefined;
4
+ //
5
+ // try {
6
+ // web3 = require('@solana/web3.js');
7
+ // base58 = require('bs58');
8
+ // } catch (e) {}
9
+ //
10
+ // export {web3, base58};
11
+ // This works in react, but not angular
12
+ import * as SolanaWeb3Js from '@solana/web3.js';
13
+ import base58Imported from 'bs58';
14
+ var web3 = SolanaWeb3Js;
15
+ var base58 = base58Imported;
16
+ export { web3, base58 };
17
+ //# sourceMappingURL=SolanaPeerDeps.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"SolanaPeerDeps.js","sourceRoot":"","sources":["../../../src/common/SolanaPeerDeps.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,0DAA0D;AAC1D,iDAAiD;AACjD,EAAE;AACF,QAAQ;AACR,uCAAuC;AACvC,8BAA8B;AAC9B,iBAAiB;AACjB,EAAE;AACF,yBAAyB;AAEzB,uCAAuC;AACvC,OAAO,KAAK,YAAY,MAAM,iBAAiB,CAAC;AAChD,OAAO,cAAc,MAAM,MAAM,CAAC;AAElC,IAAM,IAAI,GAAoC,YAAY,CAAC;AAC3D,IAAM,MAAM,GAAsC,cAAc,CAAC;AACjE,OAAO,EAAC,IAAI,EAAE,MAAM,EAAC,CAAC"}
@@ -0,0 +1,3 @@
1
+ export * from './CoinflowTypes';
2
+ export * from './CoinflowUtils';
3
+ export * from './CoinflowLibMessageHandlers';
@@ -0,0 +1,4 @@
1
+ export * from './CoinflowTypes';
2
+ export * from './CoinflowUtils';
3
+ export * from './CoinflowLibMessageHandlers';
4
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/common/index.ts"],"names":[],"mappings":"AAAA,cAAc,iBAAiB,CAAC;AAChC,cAAc,iBAAiB,CAAC;AAChC,cAAc,8BAA8B,CAAC"}
@@ -1,11 +1,9 @@
1
1
  export * from './CoinflowWithdraw';
2
2
  export * from './CoinflowPurchase';
3
- export * from './CoinflowUtils';
4
- export * from './wallet/useIframeWallet';
3
+ export * from './common';
5
4
  export * from './CoinflowIFrame';
6
5
  export * from './CoinflowPurchaseHistory';
7
6
  export * from './CoinflowWithdrawHistory';
8
- export * from './CoinflowTypes';
9
7
  export * from './CoinflowPurchaseProtection';
10
8
  export * from './CoinflowCardForm';
11
9
  export * from './CoinflowApplePayButton';
@@ -1,11 +1,9 @@
1
1
  export * from './CoinflowWithdraw';
2
2
  export * from './CoinflowPurchase';
3
- export * from './CoinflowUtils';
4
- export * from './wallet/useIframeWallet';
3
+ export * from './common';
5
4
  export * from './CoinflowIFrame';
6
5
  export * from './CoinflowPurchaseHistory';
7
6
  export * from './CoinflowWithdrawHistory';
8
- export * from './CoinflowTypes';
9
7
  export * from './CoinflowPurchaseProtection';
10
8
  export * from './CoinflowCardForm';
11
9
  export * from './CoinflowApplePayButton';
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,oBAAoB,CAAC;AACnC,cAAc,oBAAoB,CAAC;AACnC,cAAc,iBAAiB,CAAC;AAChC,cAAc,0BAA0B,CAAC;AACzC,cAAc,kBAAkB,CAAC;AACjC,cAAc,2BAA2B,CAAC;AAC1C,cAAc,2BAA2B,CAAC;AAC1C,cAAc,iBAAiB,CAAC;AAChC,cAAc,8BAA8B,CAAC;AAC7C,cAAc,oBAAoB,CAAC;AACnC,cAAc,0BAA0B,CAAC;AACzC,cAAc,2BAA2B,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,oBAAoB,CAAC;AACnC,cAAc,oBAAoB,CAAC;AACnC,cAAc,UAAU,CAAC;AACzB,cAAc,kBAAkB,CAAC;AACjC,cAAc,2BAA2B,CAAC;AAC1C,cAAc,2BAA2B,CAAC;AAC1C,cAAc,8BAA8B,CAAC;AAC7C,cAAc,oBAAoB,CAAC;AACnC,cAAc,0BAA0B,CAAC;AACzC,cAAc,2BAA2B,CAAC"}