coinley-checkout 1.2.0 → 1.2.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.
@@ -34,7 +34,7 @@ var __privateMethod = (obj, member, method) => {
34
34
  __accessCheck(obj, member, "access private method");
35
35
  return method;
36
36
  };
37
- var _listener, _listeners, _cancelled, _allowInsecure, _gzip, _headers, _method, _timeout, _url, _body, _bodyType, _creds, _preflight, _process, _retry, _signal, _throttle, _getUrlFunc, _send, send_fn, _statusCode, _statusMessage, _headers2, _body2, _request, _error, _format, _val, _tens, _checkFormat, checkFormat_fn, _checkValue, checkValue_fn, _add, add_fn, _sub, sub_fn, _mul, mul_fn, _div, div_fn, _names, _data, _dataLength, _writeData, writeData_fn, _data2, _offset, _bytesRead, _parent, _maxInflation, _incrementBytesRead, incrementBytesRead_fn, _peekBytes, peekBytes_fn, _r, _s, _v, _networkV, _privateKey, _options, _type, _to, _data3, _nonce, _gasLimit, _gasPrice, _maxPriorityFeePerGas, _maxFeePerGas, _value, _chainId, _sig, _accessList, _maxFeePerBlobGas, _blobVersionedHashes, _kzg, _blobs, _auths, _getSerialized, getSerialized_fn, _types, _fullTypes, _encoderCache, _getEncoder, getEncoder_fn, _offset2, _tokens, _subTokenString, subTokenString_fn, _walkAsync, walkAsync_fn, _getCoder, getCoder_fn, _errors, _events, _functions, _abiCoder, _getFunction, getFunction_fn, _getEvent, getEvent_fn, _transactions, _logs, _startBlock, _iface, _iface2, _filter, _a, _supports2544, _resolver, _fetch, fetch_fn, _getResolver, getResolver_fn, _url2, _processFunc, _name, _chainId2, _plugins, _provider, _poller, _interval, _blockNumber, _poll, poll_fn, _provider2, _poll2, _running, _tag, _lastBlock, _filter2, _hash, _provider3, _filter3, _poller2, _running2, _blockNumber2, _poll3, poll_fn2, _subs, _plugins2, _pausedState, _destroyed, _networkPromise, _anyNetwork, _performCache, _lastBlockNumber, _nextTimer, _timers, _disableCcipRead, _options2, _perform, perform_fn, _call, call_fn, _checkNetwork, checkNetwork_fn, _getAccountValue, getAccountValue_fn, _getBlock, getBlock_fn, _hasSub, hasSub_fn, _getSub, getSub_fn, _provider4, _filterIdPromise, _poller3, _running3, _network, _hault, _poll4, poll_fn3, _teardown, teardown_fn, _event, _options3, _nextId, _payloads, _drainTimer, _notReady, _network2, _pendingDetectNetwork, _scheduleDrain, scheduleDrain_fn, _pollingInterval, _request2, _providerInfo;
37
+ var _listener, _listeners, _cancelled, _allowInsecure, _gzip, _headers, _method, _timeout, _url, _body, _bodyType, _creds, _preflight, _process, _retry, _signal, _throttle, _getUrlFunc, _send, send_fn, _statusCode, _statusMessage, _headers2, _body2, _request, _error, _format, _val, _tens, _checkFormat, checkFormat_fn, _checkValue, checkValue_fn, _add, add_fn, _sub, sub_fn, _mul, mul_fn, _div, div_fn, _names, _data, _dataLength, _writeData, writeData_fn, _data2, _offset, _bytesRead, _parent, _maxInflation, _incrementBytesRead, incrementBytesRead_fn, _peekBytes, peekBytes_fn, _r, _s, _v, _networkV, _privateKey, _options, _type, _to, _data3, _nonce, _gasLimit, _gasPrice, _maxPriorityFeePerGas, _maxFeePerGas, _value, _chainId, _sig, _accessList, _maxFeePerBlobGas, _blobVersionedHashes, _kzg, _blobs, _auths, _getSerialized, getSerialized_fn, _a, _types, _fullTypes, _encoderCache, _getEncoder, getEncoder_fn, _offset2, _tokens, _subTokenString, subTokenString_fn, _walkAsync, walkAsync_fn, _getCoder, getCoder_fn, _errors, _events, _functions, _abiCoder, _getFunction, getFunction_fn, _getEvent, getEvent_fn, _transactions, _logs, _startBlock, _iface, _iface2, _filter, _b, _supports2544, _resolver, _fetch, fetch_fn, _getResolver, getResolver_fn, _url2, _processFunc, _name, _chainId2, _plugins, _provider, _poller, _interval, _blockNumber, _poll, poll_fn, _provider2, _poll2, _running, _tag, _lastBlock, _filter2, _hash, _provider3, _filter3, _poller2, _running2, _blockNumber2, _poll3, poll_fn2, _subs, _plugins2, _pausedState, _destroyed, _networkPromise, _anyNetwork, _performCache, _lastBlockNumber, _nextTimer, _timers, _disableCcipRead, _options2, _perform, perform_fn, _call, call_fn, _checkNetwork, checkNetwork_fn, _getAccountValue, getAccountValue_fn, _getBlock, getBlock_fn, _hasSub, hasSub_fn, _getSub, getSub_fn, _provider4, _filterIdPromise, _poller3, _running3, _network, _hault, _poll4, poll_fn3, _teardown, teardown_fn, _event, _options3, _nextId, _payloads, _drainTimer, _notReady, _network2, _pendingDetectNetwork, _scheduleDrain, scheduleDrain_fn, _pollingInterval, _request2, _providerInfo;
38
38
  import React, { createContext, useContext, useState, useEffect, useRef, forwardRef, useImperativeHandle } from "react";
39
39
  const styles = "";
40
40
  const version = "6.14.3";
@@ -1284,7 +1284,7 @@ _throttle = new WeakMap();
1284
1284
  _getUrlFunc = new WeakMap();
1285
1285
  _send = new WeakSet();
1286
1286
  send_fn = async function(attempt, expires, delay, _request3, _response) {
1287
- var _a2, _b, _c;
1287
+ var _a2, _b2, _c;
1288
1288
  if (attempt >= __privateGet(this, _throttle).maxAttempts) {
1289
1289
  return _response.makeServerError("exceeded maximum retry limit");
1290
1290
  }
@@ -1335,7 +1335,7 @@ send_fn = async function(attempt, expires, delay, _request3, _response) {
1335
1335
  if (typeof retryAfter === "string" && retryAfter.match(/^[1-9][0-9]*$/)) {
1336
1336
  delay2 = parseInt(retryAfter);
1337
1337
  }
1338
- return __privateMethod(_b = req.clone(), _send, send_fn).call(_b, attempt + 1, expires, delay2, _request3, response);
1338
+ return __privateMethod(_b2 = req.clone(), _send, send_fn).call(_b2, attempt + 1, expires, delay2, _request3, response);
1339
1339
  }
1340
1340
  }
1341
1341
  if (this.processFunc) {
@@ -7157,7 +7157,7 @@ function _serializeEip7702(tx, sig) {
7157
7157
  }
7158
7158
  return concat(["0x04", encodeRlp(fields)]);
7159
7159
  }
7160
- const _Transaction = class _Transaction {
7160
+ let Transaction$1 = (_a = class {
7161
7161
  /**
7162
7162
  * Creates a new Transaction with default values.
7163
7163
  */
@@ -7686,7 +7686,7 @@ const _Transaction = class _Transaction {
7686
7686
  * Create a copy of this transaciton.
7687
7687
  */
7688
7688
  clone() {
7689
- return _Transaction.from(this);
7689
+ return _a.from(this);
7690
7690
  }
7691
7691
  /**
7692
7692
  * Return a JSON-friendly object.
@@ -7720,26 +7720,26 @@ const _Transaction = class _Transaction {
7720
7720
  */
7721
7721
  static from(tx) {
7722
7722
  if (tx == null) {
7723
- return new _Transaction();
7723
+ return new _a();
7724
7724
  }
7725
7725
  if (typeof tx === "string") {
7726
7726
  const payload = getBytes(tx);
7727
7727
  if (payload[0] >= 127) {
7728
- return _Transaction.from(_parseLegacy(payload));
7728
+ return _a.from(_parseLegacy(payload));
7729
7729
  }
7730
7730
  switch (payload[0]) {
7731
7731
  case 1:
7732
- return _Transaction.from(_parseEip2930(payload));
7732
+ return _a.from(_parseEip2930(payload));
7733
7733
  case 2:
7734
- return _Transaction.from(_parseEip1559(payload));
7734
+ return _a.from(_parseEip1559(payload));
7735
7735
  case 3:
7736
- return _Transaction.from(_parseEip4844(payload));
7736
+ return _a.from(_parseEip4844(payload));
7737
7737
  case 4:
7738
- return _Transaction.from(_parseEip7702(payload));
7738
+ return _a.from(_parseEip7702(payload));
7739
7739
  }
7740
7740
  assert(false, "unsupported transaction type", "UNSUPPORTED_OPERATION", { operation: "from" });
7741
7741
  }
7742
- const result = new _Transaction();
7742
+ const result = new _a();
7743
7743
  if (tx.type != null) {
7744
7744
  result.type = tx.type;
7745
7745
  }
@@ -7801,26 +7801,7 @@ const _Transaction = class _Transaction {
7801
7801
  }
7802
7802
  return result;
7803
7803
  }
7804
- };
7805
- _type = new WeakMap();
7806
- _to = new WeakMap();
7807
- _data3 = new WeakMap();
7808
- _nonce = new WeakMap();
7809
- _gasLimit = new WeakMap();
7810
- _gasPrice = new WeakMap();
7811
- _maxPriorityFeePerGas = new WeakMap();
7812
- _maxFeePerGas = new WeakMap();
7813
- _value = new WeakMap();
7814
- _chainId = new WeakMap();
7815
- _sig = new WeakMap();
7816
- _accessList = new WeakMap();
7817
- _maxFeePerBlobGas = new WeakMap();
7818
- _blobVersionedHashes = new WeakMap();
7819
- _kzg = new WeakMap();
7820
- _blobs = new WeakMap();
7821
- _auths = new WeakMap();
7822
- _getSerialized = new WeakSet();
7823
- getSerialized_fn = function(signed2, sidecar) {
7804
+ }, _type = new WeakMap(), _to = new WeakMap(), _data3 = new WeakMap(), _nonce = new WeakMap(), _gasLimit = new WeakMap(), _gasPrice = new WeakMap(), _maxPriorityFeePerGas = new WeakMap(), _maxFeePerGas = new WeakMap(), _value = new WeakMap(), _chainId = new WeakMap(), _sig = new WeakMap(), _accessList = new WeakMap(), _maxFeePerBlobGas = new WeakMap(), _blobVersionedHashes = new WeakMap(), _kzg = new WeakMap(), _blobs = new WeakMap(), _auths = new WeakMap(), _getSerialized = new WeakSet(), getSerialized_fn = function(signed2, sidecar) {
7824
7805
  assert(!signed2 || this.signature != null, "cannot serialize unsigned transaction; maybe you meant .unsignedSerialized", "UNSUPPORTED_OPERATION", { operation: ".serialized" });
7825
7806
  const sig = signed2 ? this.signature : null;
7826
7807
  switch (this.inferType()) {
@@ -7836,8 +7817,7 @@ getSerialized_fn = function(signed2, sidecar) {
7836
7817
  return _serializeEip7702(this, sig);
7837
7818
  }
7838
7819
  assert(false, "unsupported transaction type", "UNSUPPORTED_OPERATION", { operation: ".serialized" });
7839
- };
7840
- let Transaction = _Transaction;
7820
+ }, _a);
7841
7821
  function id(value) {
7842
7822
  return keccak256(toUtf8Bytes(value));
7843
7823
  }
@@ -13540,7 +13520,7 @@ const _BaseContract = class _BaseContract {
13540
13520
  /**
13541
13521
  * @_ignore:
13542
13522
  */
13543
- __publicField(this, _a);
13523
+ __publicField(this, _b);
13544
13524
  /**
13545
13525
  * The fallback or receive function if any.
13546
13526
  */
@@ -13931,7 +13911,7 @@ const _BaseContract = class _BaseContract {
13931
13911
  return contract;
13932
13912
  }
13933
13913
  };
13934
- _a = internal;
13914
+ _b = internal;
13935
13915
  let BaseContract = _BaseContract;
13936
13916
  function _ContractBase() {
13937
13917
  return BaseContract;
@@ -15928,7 +15908,7 @@ class AbstractProvider {
15928
15908
  }),
15929
15909
  network: this.getNetwork()
15930
15910
  });
15931
- const tx = Transaction.from(signedTx);
15911
+ const tx = Transaction$1.from(signedTx);
15932
15912
  if (tx.hash !== hash2) {
15933
15913
  throw new Error("@TODO: the returned hash did not match");
15934
15914
  }
@@ -16812,7 +16792,7 @@ class AbstractSigner {
16812
16792
  const provider = checkProvider(this, "sendTransaction");
16813
16793
  const pop = await this.populateTransaction(tx);
16814
16794
  delete pop.from;
16815
- const txObj = Transaction.from(pop);
16795
+ const txObj = Transaction$1.from(pop);
16816
16796
  return await provider.broadcastTransaction(await this.signTransaction(txObj));
16817
16797
  }
16818
16798
  // @TODO: in v7 move this to be abstract
@@ -17984,6 +17964,31 @@ const _BrowserProvider = class _BrowserProvider extends JsonRpcApiPollingProvide
17984
17964
  _request2 = new WeakMap();
17985
17965
  _providerInfo = new WeakMap();
17986
17966
  let BrowserProvider = _BrowserProvider;
17967
+ let Connection, PublicKey, Transaction, SystemProgram, LAMPORTS_PER_SOL;
17968
+ let createTransferInstruction, getAssociatedTokenAddress, TOKEN_PROGRAM_ID, ASSOCIATED_TOKEN_PROGRAM_ID;
17969
+ const initializeSolanaLibraries = async () => {
17970
+ try {
17971
+ if (!Connection) {
17972
+ const solanaWeb3 = await import("@solana/web3.js");
17973
+ Connection = solanaWeb3.Connection;
17974
+ PublicKey = solanaWeb3.PublicKey;
17975
+ Transaction = solanaWeb3.Transaction;
17976
+ SystemProgram = solanaWeb3.SystemProgram;
17977
+ LAMPORTS_PER_SOL = solanaWeb3.LAMPORTS_PER_SOL;
17978
+ }
17979
+ if (!createTransferInstruction) {
17980
+ const splToken = await import("./index-e49d97f5.mjs");
17981
+ createTransferInstruction = splToken.createTransferInstruction;
17982
+ getAssociatedTokenAddress = splToken.getAssociatedTokenAddress;
17983
+ TOKEN_PROGRAM_ID = splToken.TOKEN_PROGRAM_ID;
17984
+ ASSOCIATED_TOKEN_PROGRAM_ID = splToken.ASSOCIATED_TOKEN_PROGRAM_ID;
17985
+ }
17986
+ return true;
17987
+ } catch (error) {
17988
+ console.error("Failed to initialize Solana libraries:", error);
17989
+ return false;
17990
+ }
17991
+ };
17987
17992
  const WALLET_TYPES = {
17988
17993
  METAMASK: "metamask",
17989
17994
  TRONLINK: "tronlink",
@@ -18628,6 +18633,10 @@ const sendNativeTransaction = async (walletConnection, toAddress, amount) => {
18628
18633
  if (!phantomProvider || !phantomProvider.isConnected) {
18629
18634
  throw new Error("Phantom wallet not connected");
18630
18635
  }
18636
+ const solanaInitialized = await initializeSolanaLibraries();
18637
+ if (!solanaInitialized) {
18638
+ throw new Error("Failed to initialize Solana libraries. Please ensure @solana/web3.js is installed.");
18639
+ }
18631
18640
  const amountFloat = parseFloat(amount);
18632
18641
  console.log("Phantom SOL Transaction Debug:", {
18633
18642
  originalAmount: amount,
@@ -18635,57 +18644,32 @@ const sendNativeTransaction = async (walletConnection, toAddress, amount) => {
18635
18644
  walletType: "Phantom Native SOL"
18636
18645
  });
18637
18646
  try {
18638
- if (phantomProvider.request) {
18639
- const result = await phantomProvider.request({
18640
- method: "transfer",
18641
- params: {
18642
- to: toAddress,
18643
- amount: amountFloat
18644
- // Send in SOL, not lamports
18645
- }
18646
- });
18647
- console.log("Phantom transfer result:", result);
18648
- transaction = result;
18649
- } else {
18650
- let Connection, PublicKey, Transaction2, SystemProgram, LAMPORTS_PER_SOL;
18651
- try {
18652
- const solanaWeb3 = await import("./index.browser.esm-f4fd5f63.mjs").then((n2) => n2.l);
18653
- Connection = solanaWeb3.Connection;
18654
- PublicKey = solanaWeb3.PublicKey;
18655
- Transaction2 = solanaWeb3.Transaction;
18656
- SystemProgram = solanaWeb3.SystemProgram;
18657
- LAMPORTS_PER_SOL = solanaWeb3.LAMPORTS_PER_SOL;
18658
- } catch (importError) {
18659
- console.error("Failed to import Solana libraries:", importError);
18660
- throw new Error("Solana libraries not available. Please ensure @solana/web3.js is installed.");
18661
- }
18662
- const connection = new Connection(NETWORK_CONFIG[NETWORK_TYPES.SOLANA].rpcUrl);
18663
- const fromPubkey = walletConnection.publicKey;
18664
- const toPubkey = new PublicKey(toAddress);
18665
- const lamports = Math.floor(amountFloat * LAMPORTS_PER_SOL);
18666
- console.log("Manual Solana transaction:", {
18667
- from: fromPubkey.toString(),
18668
- to: toAddress,
18669
- amountSOL: amountFloat,
18670
- lamports,
18671
- conversionCheck: `${amountFloat} SOL = ${lamports} lamports`
18672
- });
18673
- if (lamports <= 0) {
18674
- throw new Error(`Invalid amount: ${amountFloat} SOL converts to ${lamports} lamports`);
18675
- }
18676
- const transferTransaction = new Transaction2().add(
18677
- SystemProgram.transfer({
18678
- fromPubkey,
18679
- toPubkey,
18680
- lamports
18681
- })
18682
- );
18683
- const { blockhash } = await connection.getLatestBlockhash();
18684
- transferTransaction.recentBlockhash = blockhash;
18685
- transferTransaction.feePayer = fromPubkey;
18686
- const signedTransaction = await phantomProvider.signAndSendTransaction(transferTransaction);
18687
- transaction = signedTransaction;
18647
+ const connection = new Connection(NETWORK_CONFIG[NETWORK_TYPES.SOLANA].rpcUrl);
18648
+ const fromPubkey = walletConnection.publicKey;
18649
+ const toPubkey = new PublicKey(toAddress);
18650
+ const lamports = Math.floor(amountFloat * LAMPORTS_PER_SOL);
18651
+ console.log("Solana native transaction:", {
18652
+ from: fromPubkey.toString(),
18653
+ to: toAddress,
18654
+ amountSOL: amountFloat,
18655
+ lamports,
18656
+ conversionCheck: `${amountFloat} SOL = ${lamports} lamports`
18657
+ });
18658
+ if (lamports <= 0) {
18659
+ throw new Error(`Invalid amount: ${amountFloat} SOL converts to ${lamports} lamports`);
18688
18660
  }
18661
+ const transferTransaction = new Transaction().add(
18662
+ SystemProgram.transfer({
18663
+ fromPubkey,
18664
+ toPubkey,
18665
+ lamports
18666
+ })
18667
+ );
18668
+ const { blockhash } = await connection.getLatestBlockhash();
18669
+ transferTransaction.recentBlockhash = blockhash;
18670
+ transferTransaction.feePayer = fromPubkey;
18671
+ const signedTransaction = await phantomProvider.signAndSendTransaction(transferTransaction);
18672
+ transaction = signedTransaction;
18689
18673
  } catch (phantomError) {
18690
18674
  console.error("Phantom transaction error:", phantomError);
18691
18675
  throw new Error(`Phantom transaction failed: ${phantomError.message || "Unknown error"}`);
@@ -18751,7 +18735,6 @@ const sendTokenTransaction = async (walletConnection, tokenConfig, toAddress, am
18751
18735
  const sendSolanaTokenTransaction = async (walletConnection, tokenConfig, toAddress, amount) => {
18752
18736
  console.log("=== SOLANA TOKEN TRANSACTION DEBUG ===");
18753
18737
  console.log("Input params:", { tokenConfig, toAddress, amount });
18754
- console.log("Wallet connection:", walletConnection);
18755
18738
  if (!walletConnection || !walletConnection.provider) {
18756
18739
  throw new Error("Phantom wallet not connected");
18757
18740
  }
@@ -18762,6 +18745,10 @@ const sendSolanaTokenTransaction = async (walletConnection, tokenConfig, toAddre
18762
18745
  if (!tokenConfig || !tokenConfig.contractAddress) {
18763
18746
  throw new Error("Invalid token configuration");
18764
18747
  }
18748
+ const solanaInitialized = await initializeSolanaLibraries();
18749
+ if (!solanaInitialized) {
18750
+ throw new Error("Failed to initialize Solana libraries. Please ensure @solana/web3.js and @solana/spl-token are installed.");
18751
+ }
18765
18752
  const { contractAddress, decimals, symbol } = tokenConfig;
18766
18753
  const tokenAmount = parseFloat(amount);
18767
18754
  const tokenDecimals = parseInt(decimals);
@@ -18783,24 +18770,9 @@ const sendSolanaTokenTransaction = async (walletConnection, tokenConfig, toAddre
18783
18770
  throw new Error(`Invalid amount: ${tokenAmount} ${symbol} converts to ${amountInSmallestUnit} base units`);
18784
18771
  }
18785
18772
  if (tokenAmount < 1 && amountInSmallestUnit === 0) {
18786
- throw new Error(`Amount too small: ${tokenAmount} ${symbol} is smaller than the minimum unit (1/${Math.pow(10, tokenDecimals)} ${symbol})`);
18773
+ throw new Error(`Amount too small: ${tokenAmount} ${symbol} is smaller than the minimum unit`);
18787
18774
  }
18788
18775
  try {
18789
- let Connection, PublicKey, Transaction2, createTransferInstruction, getAssociatedTokenAddress, TOKEN_PROGRAM_ID, ASSOCIATED_TOKEN_PROGRAM_ID;
18790
- try {
18791
- const solanaWeb3 = await import("./index.browser.esm-f4fd5f63.mjs").then((n2) => n2.l);
18792
- const splToken = await import("./index-0fb9796c.mjs");
18793
- Connection = solanaWeb3.Connection;
18794
- PublicKey = solanaWeb3.PublicKey;
18795
- Transaction2 = solanaWeb3.Transaction;
18796
- createTransferInstruction = splToken.createTransferInstruction;
18797
- getAssociatedTokenAddress = splToken.getAssociatedTokenAddress;
18798
- TOKEN_PROGRAM_ID = splToken.TOKEN_PROGRAM_ID;
18799
- ASSOCIATED_TOKEN_PROGRAM_ID = splToken.ASSOCIATED_TOKEN_PROGRAM_ID;
18800
- } catch (importError) {
18801
- console.error("Failed to import Solana libraries:", importError);
18802
- throw new Error("Solana libraries not available. Please ensure @solana/web3.js and @solana/spl-token are installed.");
18803
- }
18804
18776
  const connection = new Connection(NETWORK_CONFIG[NETWORK_TYPES.SOLANA].rpcUrl);
18805
18777
  const fromPubkey = walletConnection.publicKey;
18806
18778
  const toPubkey = new PublicKey(toAddress);
@@ -18837,7 +18809,7 @@ const sendSolanaTokenTransaction = async (walletConnection, tokenConfig, toAddre
18837
18809
  [],
18838
18810
  TOKEN_PROGRAM_ID
18839
18811
  );
18840
- const transaction = new Transaction2().add(transferInstruction);
18812
+ const transaction = new Transaction().add(transferInstruction);
18841
18813
  const { blockhash } = await connection.getLatestBlockhash();
18842
18814
  transaction.recentBlockhash = blockhash;
18843
18815
  transaction.feePayer = fromPubkey;
@@ -18855,7 +18827,7 @@ const sendSolanaTokenTransaction = async (walletConnection, tokenConfig, toAddre
18855
18827
  throw new Error("Insufficient token balance");
18856
18828
  } else if (error.message && error.message.includes("Invalid amount") || error.message && error.message.includes("Amount too small")) {
18857
18829
  throw error;
18858
- } else if (error.message && error.message.includes("Solana libraries not available")) {
18830
+ } else if (error.message && error.message.includes("Failed to initialize Solana libraries")) {
18859
18831
  throw error;
18860
18832
  } else {
18861
18833
  throw new Error(`Token transaction failed: ${error.message || "Unknown error"}`);
@@ -20423,7 +20395,7 @@ var QRCodeCanvas = React.forwardRef(
20423
20395
  "marginSize",
20424
20396
  "imageSettings"
20425
20397
  ]);
20426
- const _b = extraProps, { style } = _b, otherProps = __objRest(_b, ["style"]);
20398
+ const _b2 = extraProps, { style } = _b2, otherProps = __objRest(_b2, ["style"]);
20427
20399
  const imgSrc = imageSettings == null ? void 0 : imageSettings.src;
20428
20400
  const _canvas = React.useRef(null);
20429
20401
  const _image = React.useRef(null);