@imtbl/sdk 1.51.4 → 1.51.5-alpha
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/dist/{blockchain_data-CQ6AoMx9.js → blockchain_data-BWhpazG1.js} +2 -2
- package/dist/blockchain_data.js +3 -3
- package/dist/browser/checkout/{AddFundsWidget-B6lxg3-d.js → AddFundsWidget-BSFSJRHi.js} +2 -2
- package/dist/browser/checkout/{BridgeWidget-BsJMfbMd.js → BridgeWidget-BCXX3J9w.js} +5 -5
- package/dist/browser/checkout/{CheckoutWidget-DFkDATHf.js → CheckoutWidget-B9XU5Y23.js} +32 -8
- package/dist/browser/checkout/{OnRampWidget-QHUxzsNL.js → OnRampWidget-CSyw8VbN.js} +3 -3
- package/dist/browser/checkout/{SaleWidget-6XVHHx78.js → SaleWidget-DmSKDNme.js} +9 -9
- package/dist/browser/checkout/{SpendingCapHero-BOGiq2Br.js → SpendingCapHero-CR_GKE4n.js} +1 -1
- package/dist/browser/checkout/{SwapWidget-CRLt7sOf.js → SwapWidget-DTIU8lHF.js} +6 -6
- package/dist/browser/checkout/{TextInputForm-DTMMP9L1.js → TextInputForm-DF6GHHYm.js} +1 -1
- package/dist/browser/checkout/{TopUpView-CMKjjqCh.js → TopUpView-BrkwD9G7.js} +1 -1
- package/dist/browser/checkout/{WalletWidget-CL4wDvCI.js → WalletWidget-D562MwM2.js} +3 -3
- package/dist/browser/checkout/{auto-track-CtPV_Uwy.js → auto-track-5ICaJzRc.js} +1 -1
- package/dist/browser/checkout/{balance-6n0VLt18.js → balance-Cek1goAE.js} +2 -2
- package/dist/browser/checkout/{index-DEnK71D8.js → index-BY8yisGB.js} +2 -2
- package/dist/browser/checkout/{index-DNulskt6.js → index-BwLAtG5_.js} +1 -1
- package/dist/browser/checkout/{index-CW0LGbJg.js → index-CABfXrFM.js} +1 -1
- package/dist/browser/checkout/{index-C4G5HCXv.js → index-C_y79evo.js} +1 -1
- package/dist/browser/checkout/{index-U6OI_-oo.js → index-ChiGN74Y.js} +1 -1
- package/dist/browser/checkout/{index-CjshWKlm.js → index-DL5wHEr2.js} +18 -18
- package/dist/browser/checkout/{index-DJD5AByC.js → index-Es_ymVzs.js} +1 -1
- package/dist/browser/checkout/{index-D0vPA5zH.js → index-gZkMFimN.js} +1 -1
- package/dist/browser/checkout/{index.umd-CfvJk2bO.js → index.umd-PqfnAPwt.js} +1 -1
- package/dist/browser/checkout/{retry-CVrWwmTg.js → retry-DE9iUZQz.js} +1 -1
- package/dist/browser/checkout/sdk.js +4 -4
- package/dist/browser/checkout/widgets-esm.js +1 -1
- package/dist/browser/checkout/widgets.js +35 -11
- package/dist/{checkout-DWWjqlwt.js → checkout-gNsm72GY.js} +5 -5
- package/dist/checkout.js +5 -5
- package/dist/{config-FDLZHCQt.js → config-CWc0j0qL.js} +1 -1
- package/dist/config.js +1 -1
- package/dist/{index-Ce6q7YQY.js → index-BDK4MHRD.js} +1 -1
- package/dist/{index-D1Aaqwa8.js → index-BPJR89WF.js} +1 -1
- package/dist/{index-Dkz_P59Z.js → index-BQ1_8BfM.js} +4 -4
- package/dist/{index-CX-NVI5Y.js → index-LTCOac91.js} +3 -3
- package/dist/{index-5C4exz-O.js → index-emng9CKB.js} +1 -1
- package/dist/{index-DOh9aDU4.js → index-z1vwQX9u.js} +1 -1
- package/dist/index.browser.js +4 -4
- package/dist/index.browser.js.map +1 -1
- package/dist/index.cjs +7 -7
- package/dist/index.js +14 -14
- package/dist/{minting_backend-DEeSw0bb.js → minting_backend-lq7Qls0A.js} +3 -3
- package/dist/minting_backend.js +5 -5
- package/dist/{orderbook-Cch6Renl.js → orderbook-DirKtRF8.js} +1 -1
- package/dist/orderbook.js +2 -2
- package/dist/{passport-DahmnAXM.js → passport-DmmkRZ5a.js} +3 -3
- package/dist/passport.js +4 -4
- package/dist/{webhook-pHPtczr8.js → webhook-Bkk2lXTs.js} +1 -1
- package/dist/webhook.js +2 -2
- package/dist/{x-4yU9GbGY.js → x-dPBW2F31.js} +3 -3
- package/dist/x.js +4 -4
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
export { dk as WidgetsFactory } from './index-
|
|
1
|
+
export { dk as WidgetsFactory } from './index-DL5wHEr2.js';
|
|
@@ -206534,7 +206534,7 @@ function print() { __p += __j.call(arguments, '') }
|
|
|
206534
206534
|
* @param shouldMount function to check mount condition
|
|
206535
206535
|
* @param deps dependencies to watch for changes
|
|
206536
206536
|
*/
|
|
206537
|
-
const useMount = (fn, shouldMount, deps) => {
|
|
206537
|
+
const useMount$1 = (fn, shouldMount, deps) => {
|
|
206538
206538
|
const isMounted = reactExports.useRef(false);
|
|
206539
206539
|
const shouldMountCheck = () => {
|
|
206540
206540
|
if (typeof shouldMount === 'function') {
|
|
@@ -206642,7 +206642,7 @@ function print() { __p += __j.call(arguments, '') }
|
|
|
206642
206642
|
const title = heading ? t(...heading) : t('views.TOP_UP_VIEW.header.title');
|
|
206643
206643
|
const description = subheading ? t(...subheading) : null;
|
|
206644
206644
|
const { page, track } = useAnalytics();
|
|
206645
|
-
useMount(() => {
|
|
206645
|
+
useMount$1(() => {
|
|
206646
206646
|
page({
|
|
206647
206647
|
userJourney,
|
|
206648
206648
|
screen: 'TopUp',
|
|
@@ -211484,7 +211484,7 @@ function print() { __p += __j.call(arguments, '') }
|
|
|
211484
211484
|
});
|
|
211485
211485
|
}, [fundingBalance, conversions, provider]);
|
|
211486
211486
|
// Trigger page loaded event
|
|
211487
|
-
useMount(() => {
|
|
211487
|
+
useMount$1(() => {
|
|
211488
211488
|
const tokens = fundingBalances.map((fb) => getPaymentTokenDetails(fb, conversions));
|
|
211489
211489
|
sendPageView(SaleWidgetViews.ORDER_SUMMARY, {
|
|
211490
211490
|
subView: OrderSummarySubViews.REVIEW_ORDER,
|
|
@@ -215028,7 +215028,7 @@ function print() { __p += __j.call(arguments, '') }
|
|
|
215028
215028
|
const { addHandover } = useHandover({
|
|
215029
215029
|
id: HandoverTarget.GLOBAL,
|
|
215030
215030
|
});
|
|
215031
|
-
useMount(() => {
|
|
215031
|
+
useMount$1(() => {
|
|
215032
215032
|
addHandover({
|
|
215033
215033
|
duration,
|
|
215034
215034
|
animationUrl,
|
|
@@ -215756,6 +215756,23 @@ function print() { __p += __j.call(arguments, '') }
|
|
|
215756
215756
|
return [baseURL, iframeURL];
|
|
215757
215757
|
};
|
|
215758
215758
|
|
|
215759
|
+
/**
|
|
215760
|
+
* This hook is used to run an effect only once when after the component is mounted.
|
|
215761
|
+
* and all dependencies are either by default not undefined or the compare function returns true.
|
|
215762
|
+
*/
|
|
215763
|
+
const useMount = (effect, deps, compare) => {
|
|
215764
|
+
const hasRunRef = reactExports.useRef(false);
|
|
215765
|
+
reactExports.useEffect(() => {
|
|
215766
|
+
const allDepsSatisfy = compare
|
|
215767
|
+
? compare(deps)
|
|
215768
|
+
: deps.every((dep) => dep !== undefined);
|
|
215769
|
+
if (!hasRunRef.current && allDepsSatisfy) {
|
|
215770
|
+
hasRunRef.current = true;
|
|
215771
|
+
effect();
|
|
215772
|
+
}
|
|
215773
|
+
}, [deps, effect, compare]);
|
|
215774
|
+
};
|
|
215775
|
+
|
|
215759
215776
|
function CheckoutWidget(props) {
|
|
215760
215777
|
const { config, checkout, params, provider, } = props;
|
|
215761
215778
|
const [, iframeURL] = reactExports.useMemo(() => {
|
|
@@ -215765,17 +215782,24 @@ function print() { __p += __j.call(arguments, '') }
|
|
|
215765
215782
|
}, [params, config, checkout.config]);
|
|
215766
215783
|
const [checkoutState, checkoutDispatch] = reactExports.useReducer(checkoutReducer, initialCheckoutState);
|
|
215767
215784
|
const checkoutReducerValues = reactExports.useMemo(() => ({
|
|
215768
|
-
checkoutState: {
|
|
215769
|
-
...checkoutState, iframeURL, checkout,
|
|
215770
|
-
},
|
|
215785
|
+
checkoutState: { ...checkoutState, iframeURL, checkout },
|
|
215771
215786
|
checkoutDispatch,
|
|
215772
215787
|
}), [checkoutState, checkoutDispatch, iframeURL, checkout]);
|
|
215788
|
+
// If the widget was initialized with a provider,
|
|
215789
|
+
// notify iframe via postMessage
|
|
215790
|
+
const { postMessageHandler } = checkoutState;
|
|
215791
|
+
useMount(() => {
|
|
215792
|
+
if (!provider)
|
|
215793
|
+
return;
|
|
215794
|
+
postMessageHandler?.send(PostMessageHandlerEventType.PROVIDER_UPDATED, {
|
|
215795
|
+
isMetamask: provider.provider.isMetaMask,
|
|
215796
|
+
isPassport: provider.provider?.isPassport,
|
|
215797
|
+
});
|
|
215798
|
+
}, [postMessageHandler, provider], ([_postMessageHandler]) => _postMessageHandler !== undefined);
|
|
215799
|
+
// keep the provider updated in the state
|
|
215773
215800
|
reactExports.useEffect(() => {
|
|
215774
215801
|
checkoutDispatch({
|
|
215775
|
-
payload: {
|
|
215776
|
-
type: CheckoutActions.SET_PROVIDER,
|
|
215777
|
-
provider,
|
|
215778
|
-
},
|
|
215802
|
+
payload: { type: CheckoutActions.SET_PROVIDER, provider },
|
|
215779
215803
|
});
|
|
215780
215804
|
}, [provider]);
|
|
215781
215805
|
return (jsx$1(CheckoutContextProvider, { values: checkoutReducerValues, children: jsx$1(CheckoutAppIframe, {}) }));
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { E as Environment$1, t as track, I as ImmutableConfiguration } from './index-
|
|
1
|
+
import { E as Environment$1, t as track, I as ImmutableConfiguration } from './index-BDK4MHRD.js';
|
|
2
2
|
import { ethers, BigNumber as BigNumber$1, ContractFactory, utils as utils$2, Contract as Contract$1 } from 'ethers';
|
|
3
3
|
import globalAxios, { HttpStatusCode as HttpStatusCode$1 } from 'axios';
|
|
4
4
|
import { Web3Provider, JsonRpcProvider } from '@ethersproject/providers';
|
|
@@ -9,8 +9,8 @@ import assert from 'assert';
|
|
|
9
9
|
import { FeeAmount, Route, SwapQuoter, Pool, Trade, toHex as toHex$1, encodeRouteToPath } from '@uniswap/v3-sdk';
|
|
10
10
|
import { keccak256 as keccak256$1 } from '@ethersproject/solidity';
|
|
11
11
|
import { SwapRouter, PaymentsExtended } from '@uniswap/router-sdk';
|
|
12
|
-
import { c as constants, O as OrderStatusName, a as Orderbook, A as ActionType, T as TransactionPurpose, S as SignablePurpose } from './index-
|
|
13
|
-
import { B as BlockchainData } from './index-
|
|
12
|
+
import { c as constants, O as OrderStatusName, a as Orderbook, A as ActionType, T as TransactionPurpose, S as SignablePurpose } from './index-emng9CKB.js';
|
|
13
|
+
import { B as BlockchainData } from './index-LTCOac91.js';
|
|
14
14
|
|
|
15
15
|
function bind(fn, thisArg) {
|
|
16
16
|
return function wrap() {
|
|
@@ -19206,7 +19206,7 @@ const flattenProperties = (properties) => {
|
|
|
19206
19206
|
};
|
|
19207
19207
|
|
|
19208
19208
|
// WARNING: DO NOT CHANGE THE STRING BELOW. IT GETS REPLACED AT BUILD TIME.
|
|
19209
|
-
const SDK_VERSION = '1.51.
|
|
19209
|
+
const SDK_VERSION = '1.51.5-alpha';
|
|
19210
19210
|
const getFrameParentDomain = () => {
|
|
19211
19211
|
if (isNode()) {
|
|
19212
19212
|
return '';
|
|
@@ -24600,7 +24600,7 @@ const IMMUTABLE_ZKVEM_GAS_OVERRIDES = {
|
|
|
24600
24600
|
maxPriorityFeePerGas: BigNumber$1.from(10e9),
|
|
24601
24601
|
};
|
|
24602
24602
|
|
|
24603
|
-
const SDK_VERSION_MARKER = '1.51.
|
|
24603
|
+
const SDK_VERSION_MARKER = '1.51.5-alpha';
|
|
24604
24604
|
// This SDK version is replaced by the `yarn build` command ran on the root level
|
|
24605
24605
|
const globalPackageVersion = () => SDK_VERSION_MARKER;
|
|
24606
24606
|
|
package/dist/checkout.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export { A as AddFundsEventType, B as BlockExplorerService, a as BridgeEventType, C as ChainId, b as ChainName, d as ChainSlug, e as Checkout, f as CheckoutConfiguration, g as CheckoutErrorType, h as CheckoutEventType, i as CheckoutFailureEventType, j as CheckoutFlowType, k as CheckoutStatus, l as CheckoutSuccessEventType, m as CheckoutUserActionEventType, n as ConnectEventType, o as ConnectTargetLayer, E as ExchangeType, F as FeeType, p as FundingStepType, G as GasEstimateType, q as GasTokenType, I as IMMUTABLE_API_BASE_URL, r as IMTBLWidgetEvents, s as ItemType, N as NetworkFilterTypes, O as OnRampEventType, t as OrchestrationEventType, P as PostMessageHandler, u as PostMessageHandlerEventType, v as ProviderEventType, R as RoutingOutcomeType, S as SaleEventType, w as SalePaymentTypes, x as SwapDirection, y as SwapEventType, T as TokenFilterTypes, z as TransactionOrGasType, W as WalletEventType, D as WalletFilterTypes, H as WalletProviderName, J as WalletProviderRdns, K as WidgetTheme, L as WidgetType, M as getMetaMaskProviderDetail, Q as getPassportProviderDetail, U as isAddressSanctioned, V as validateProvider } from './checkout-
|
|
2
|
-
import './index-
|
|
1
|
+
export { A as AddFundsEventType, B as BlockExplorerService, a as BridgeEventType, C as ChainId, b as ChainName, d as ChainSlug, e as Checkout, f as CheckoutConfiguration, g as CheckoutErrorType, h as CheckoutEventType, i as CheckoutFailureEventType, j as CheckoutFlowType, k as CheckoutStatus, l as CheckoutSuccessEventType, m as CheckoutUserActionEventType, n as ConnectEventType, o as ConnectTargetLayer, E as ExchangeType, F as FeeType, p as FundingStepType, G as GasEstimateType, q as GasTokenType, I as IMMUTABLE_API_BASE_URL, r as IMTBLWidgetEvents, s as ItemType, N as NetworkFilterTypes, O as OnRampEventType, t as OrchestrationEventType, P as PostMessageHandler, u as PostMessageHandlerEventType, v as ProviderEventType, R as RoutingOutcomeType, S as SaleEventType, w as SalePaymentTypes, x as SwapDirection, y as SwapEventType, T as TokenFilterTypes, z as TransactionOrGasType, W as WalletEventType, D as WalletFilterTypes, H as WalletProviderName, J as WalletProviderRdns, K as WidgetTheme, L as WidgetType, M as getMetaMaskProviderDetail, Q as getPassportProviderDetail, U as isAddressSanctioned, V as validateProvider } from './checkout-gNsm72GY.js';
|
|
2
|
+
import './index-BDK4MHRD.js';
|
|
3
3
|
import 'axios';
|
|
4
4
|
import 'lru-memorise';
|
|
5
5
|
import 'global-const';
|
|
@@ -11,10 +11,10 @@ import 'assert';
|
|
|
11
11
|
import '@uniswap/v3-sdk';
|
|
12
12
|
import '@ethersproject/solidity';
|
|
13
13
|
import '@uniswap/router-sdk';
|
|
14
|
-
import './index-
|
|
14
|
+
import './index-emng9CKB.js';
|
|
15
15
|
import 'form-data';
|
|
16
16
|
import 'ethers-v6';
|
|
17
17
|
import 'merkletreejs';
|
|
18
18
|
import '@opensea/seaport-js';
|
|
19
|
-
import './index-
|
|
20
|
-
import './index-
|
|
19
|
+
import './index-LTCOac91.js';
|
|
20
|
+
import './index-BPJR89WF.js';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { E as Environment, I as ImmutableConfiguration, K as KeyHeaders, a as addKeysToHeadersOverride } from './index-
|
|
1
|
+
import { E as Environment, I as ImmutableConfiguration, K as KeyHeaders, a as addKeysToHeadersOverride } from './index-BDK4MHRD.js';
|
|
2
2
|
|
|
3
3
|
var config = /*#__PURE__*/Object.freeze({
|
|
4
4
|
__proto__: null,
|
package/dist/config.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { E as Environment, I as ImmutableConfiguration, K as KeyHeaders, a as addKeysToHeadersOverride } from './index-
|
|
1
|
+
export { E as Environment, I as ImmutableConfiguration, K as KeyHeaders, a as addKeysToHeadersOverride } from './index-BDK4MHRD.js';
|
|
2
2
|
import 'axios';
|
|
3
3
|
import 'lru-memorise';
|
|
4
4
|
import 'global-const';
|
|
@@ -158,7 +158,7 @@ const flattenProperties = (properties) => {
|
|
|
158
158
|
};
|
|
159
159
|
|
|
160
160
|
// WARNING: DO NOT CHANGE THE STRING BELOW. IT GETS REPLACED AT BUILD TIME.
|
|
161
|
-
const SDK_VERSION = '1.51.
|
|
161
|
+
const SDK_VERSION = '1.51.5-alpha';
|
|
162
162
|
const getFrameParentDomain = () => {
|
|
163
163
|
if (isNode()) {
|
|
164
164
|
return '';
|
|
@@ -13838,7 +13838,7 @@ class MultiRollupApiClients {
|
|
|
13838
13838
|
}
|
|
13839
13839
|
|
|
13840
13840
|
// eslint-disable-next-line @typescript-eslint/naming-convention
|
|
13841
|
-
const defaultHeaders = { 'x-sdk-version': 'ts-immutable-sdk-1.51.
|
|
13841
|
+
const defaultHeaders = { 'x-sdk-version': 'ts-immutable-sdk-1.51.5-alpha' };
|
|
13842
13842
|
const createConfig = ({ basePath, headers, }) => {
|
|
13843
13843
|
if (!basePath.trim()) {
|
|
13844
13844
|
throw Error('basePath can not be empty');
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { b as index$2, I as ImxApiClients } from './index-
|
|
2
|
-
import { a as addKeysToHeadersOverride, E as Environment, I as ImmutableConfiguration } from './index-
|
|
1
|
+
import { b as index$2, I as ImxApiClients } from './index-BPJR89WF.js';
|
|
2
|
+
import { a as addKeysToHeadersOverride, E as Environment, I as ImmutableConfiguration } from './index-BDK4MHRD.js';
|
|
3
3
|
import globalAxios from 'axios';
|
|
4
4
|
import { keccak256 } from '@ethersproject/keccak256';
|
|
5
5
|
import { toUtf8Bytes } from '@ethersproject/strings';
|
|
@@ -16,7 +16,7 @@ import '@ethersproject/abstract-signer';
|
|
|
16
16
|
/* eslint-disable @typescript-eslint/naming-convention */
|
|
17
17
|
class ApiConfiguration extends index$2.Configuration {
|
|
18
18
|
}
|
|
19
|
-
const defaultHeaders = { 'x-sdk-version': 'ts-immutable-sdk-1.51.
|
|
19
|
+
const defaultHeaders = { 'x-sdk-version': 'ts-immutable-sdk-1.51.5-alpha' };
|
|
20
20
|
/**
|
|
21
21
|
* @dev use createImmutableXConfiguration instead
|
|
22
22
|
*/
|
|
@@ -57,7 +57,7 @@ const createImmutableXConfiguration = ({ basePath, chainID, coreContractAddress,
|
|
|
57
57
|
coreContractAddress,
|
|
58
58
|
registrationContractAddress,
|
|
59
59
|
registrationV4ContractAddress,
|
|
60
|
-
sdkVersion: 'ts-immutable-sdk-1.51.
|
|
60
|
+
sdkVersion: 'ts-immutable-sdk-1.51.5-alpha',
|
|
61
61
|
baseConfig,
|
|
62
62
|
});
|
|
63
63
|
const production = ({ baseConfig }) => createImmutableXConfiguration({
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { a as index$1 } from './index-
|
|
2
|
-
import { E as Environment, a as addKeysToHeadersOverride } from './index-
|
|
1
|
+
import { a as index$1 } from './index-BPJR89WF.js';
|
|
2
|
+
import { E as Environment, a as addKeysToHeadersOverride } from './index-BDK4MHRD.js';
|
|
3
3
|
import globalAxios from 'axios';
|
|
4
4
|
|
|
5
5
|
/**
|
|
@@ -21,7 +21,7 @@ class APIError extends Error {
|
|
|
21
21
|
|
|
22
22
|
/* eslint-disable implicit-arrow-linebreak */
|
|
23
23
|
const defaultHeaders = {
|
|
24
|
-
sdkVersion: 'ts-immutable-sdk-multi-rollup-api-client-1.51.
|
|
24
|
+
sdkVersion: 'ts-immutable-sdk-multi-rollup-api-client-1.51.5-alpha',
|
|
25
25
|
};
|
|
26
26
|
/**
|
|
27
27
|
* createAPIConfiguration to create a custom Configuration
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { t as track, E as Environment } from './index-
|
|
1
|
+
import { t as track, E as Environment } from './index-BDK4MHRD.js';
|
|
2
2
|
import globalAxios from 'axios';
|
|
3
3
|
import FormData from 'form-data';
|
|
4
4
|
import { providers, BigNumber, constants as constants$1 } from 'ethers';
|