@imtbl/sdk 1.7.1 → 1.7.3
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.d.ts +78 -34
- package/dist/blockchain_data.js +5 -4
- package/dist/browser/checkout/sdk.js +7 -7
- package/dist/browser/checkout/widgets.js +63 -63
- package/dist/checkout.d.ts +11 -0
- package/dist/checkout.js +10 -8
- package/dist/config.js +4 -3
- package/dist/index.browser.js +13 -13
- package/dist/index.browser.js.map +1 -1
- package/dist/index.cjs +30 -13
- package/dist/index.d.ts +89 -34
- package/dist/index.js +30 -13
- package/dist/orderbook.js +4 -3
- package/dist/passport.js +24 -8
- package/dist/x.js +5 -4
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -142,7 +142,7 @@ const storeDetail$1 = (key, value) => {
|
|
|
142
142
|
};
|
|
143
143
|
setItem$1(Store$1.RUNTIME, RUNTIME_DETAILS$1);
|
|
144
144
|
};
|
|
145
|
-
const getDetail$1 = (key) => {
|
|
145
|
+
const getDetail$1$1 = (key) => {
|
|
146
146
|
// Handle the scenario where detail is a falsy value
|
|
147
147
|
if (RUNTIME_DETAILS$1[key] === undefined) {
|
|
148
148
|
return undefined;
|
|
@@ -174,7 +174,7 @@ const flattenProperties$1 = (properties) => {
|
|
|
174
174
|
};
|
|
175
175
|
|
|
176
176
|
// WARNING: DO NOT CHANGE THE STRING BELOW. IT GETS REPLACED AT BUILD TIME.
|
|
177
|
-
const SDK_VERSION$1 = '1.7.
|
|
177
|
+
const SDK_VERSION$1 = '1.7.3';
|
|
178
178
|
const getReferrer$1 = () => {
|
|
179
179
|
if (isNode$1()) {
|
|
180
180
|
return '';
|
|
@@ -217,7 +217,7 @@ const initialise$2 = async () => {
|
|
|
217
217
|
initialised$1 = true;
|
|
218
218
|
try {
|
|
219
219
|
const runtimeDetails = flattenProperties$1(getRuntimeDetails$1());
|
|
220
|
-
const existingRuntimeId = getDetail$1(Detail$1.RUNTIME_ID);
|
|
220
|
+
const existingRuntimeId = getDetail$1$1(Detail$1.RUNTIME_ID);
|
|
221
221
|
const body = {
|
|
222
222
|
version: 1,
|
|
223
223
|
data: {
|
|
@@ -370,6 +370,7 @@ const setPublishableApiKeyFn$1 = (publishableApiKey) => {
|
|
|
370
370
|
storeDetail$1(Detail$1.PUBLISHABLE_API_KEY, publishableApiKey);
|
|
371
371
|
};
|
|
372
372
|
const setPublishableApiKey = errorBoundary$1(getGlobalisedValue$2('setPublishableApiKey', setPublishableApiKeyFn$1));
|
|
373
|
+
const getDetail = errorBoundary$1(getGlobalisedValue$2('getDetail', getDetail$1$1));
|
|
373
374
|
|
|
374
375
|
var Environment$1;
|
|
375
376
|
(function (Environment) {
|
|
@@ -11297,7 +11298,7 @@ class MultiRollupApiClients {
|
|
|
11297
11298
|
}
|
|
11298
11299
|
|
|
11299
11300
|
// eslint-disable-next-line @typescript-eslint/naming-convention
|
|
11300
|
-
const defaultHeaders$1 = { 'x-sdk-version': 'ts-immutable-sdk-1.7.
|
|
11301
|
+
const defaultHeaders$1 = { 'x-sdk-version': 'ts-immutable-sdk-1.7.3' };
|
|
11301
11302
|
const createConfig = ({ basePath, headers, }) => {
|
|
11302
11303
|
if (!basePath.trim()) {
|
|
11303
11304
|
throw Error('basePath can not be empty');
|
|
@@ -11369,7 +11370,7 @@ class APIError extends Error {
|
|
|
11369
11370
|
|
|
11370
11371
|
/* eslint-disable implicit-arrow-linebreak */
|
|
11371
11372
|
const defaultHeaders = {
|
|
11372
|
-
sdkVersion: 'ts-immutable-sdk-multi-rollup-api-client-1.7.
|
|
11373
|
+
sdkVersion: 'ts-immutable-sdk-multi-rollup-api-client-1.7.3',
|
|
11373
11374
|
};
|
|
11374
11375
|
/**
|
|
11375
11376
|
* createAPIConfiguration to create a custom Configuration
|
|
@@ -11802,7 +11803,7 @@ const createImmutableXConfiguration = ({ basePath, chainID, coreContractAddress,
|
|
|
11802
11803
|
chainID,
|
|
11803
11804
|
coreContractAddress,
|
|
11804
11805
|
registrationContractAddress,
|
|
11805
|
-
sdkVersion: 'ts-immutable-sdk-1.7.
|
|
11806
|
+
sdkVersion: 'ts-immutable-sdk-1.7.3',
|
|
11806
11807
|
});
|
|
11807
11808
|
/**
|
|
11808
11809
|
* Sets `sdkVersion` at the time of build
|
|
@@ -16536,10 +16537,20 @@ class AuthManager {
|
|
|
16536
16537
|
},
|
|
16537
16538
|
});
|
|
16538
16539
|
};
|
|
16539
|
-
|
|
16540
|
+
/**
|
|
16541
|
+
* login
|
|
16542
|
+
* @param anonymousId Caller can pass an anonymousId if they want to associate their user's identity with immutable's internal instrumentation.
|
|
16543
|
+
*/
|
|
16544
|
+
async login(anonymousId) {
|
|
16540
16545
|
return withPassportError(async () => {
|
|
16546
|
+
const rid = getDetail(Detail$1.RUNTIME_ID);
|
|
16541
16547
|
const popupWindowFeatures = { width: 410, height: 450 };
|
|
16542
16548
|
const oidcUser = await this.userManager.signinPopup({
|
|
16549
|
+
extraQueryParams: {
|
|
16550
|
+
...(this.userManager.settings?.extraQueryParams ?? {}),
|
|
16551
|
+
rid: rid || '',
|
|
16552
|
+
third_party_a_id: anonymousId || '',
|
|
16553
|
+
},
|
|
16543
16554
|
popupWindowFeatures,
|
|
16544
16555
|
});
|
|
16545
16556
|
return AuthManager.mapOidcUserToDomainModel(oidcUser);
|
|
@@ -16559,17 +16570,22 @@ class AuthManager {
|
|
|
16559
16570
|
async loginCallback() {
|
|
16560
16571
|
return withPassportError(async () => this.userManager.signinPopupCallback(), PassportErrorType.AUTHENTICATION_ERROR);
|
|
16561
16572
|
}
|
|
16562
|
-
|
|
16573
|
+
/**
|
|
16574
|
+
* loginWithDeviceFlow
|
|
16575
|
+
* @param anonymousId Caller can pass an anonymousId if they want to associate their user's identity with immutable's internal instrumentation.
|
|
16576
|
+
*/
|
|
16577
|
+
async loginWithDeviceFlow(anonymousId) {
|
|
16563
16578
|
return withPassportError(async () => {
|
|
16564
16579
|
const response = await globalAxios$1.post(`${this.config.authenticationDomain}/oauth/device/code`, {
|
|
16565
16580
|
client_id: this.config.oidcConfiguration.clientId,
|
|
16566
16581
|
scope: this.config.oidcConfiguration.scope,
|
|
16567
16582
|
audience: this.config.oidcConfiguration.audience,
|
|
16568
16583
|
}, formUrlEncodedHeader);
|
|
16584
|
+
const rid = getDetail(Detail$1.RUNTIME_ID);
|
|
16569
16585
|
return {
|
|
16570
16586
|
code: response.data.user_code,
|
|
16571
16587
|
deviceCode: response.data.device_code,
|
|
16572
|
-
url: response.data.verification_uri_complete
|
|
16588
|
+
url: `${response.data.verification_uri_complete}${rid ? `&rid=${rid}` : ''}${anonymousId ? `&third_party_a_id=${anonymousId}` : ''}`,
|
|
16573
16589
|
interval: response.data.interval,
|
|
16574
16590
|
};
|
|
16575
16591
|
}, PassportErrorType.AUTHENTICATION_ERROR);
|
|
@@ -37406,7 +37422,7 @@ const storeDetail = (key, value) => {
|
|
|
37406
37422
|
};
|
|
37407
37423
|
setItem(Store.RUNTIME, RUNTIME_DETAILS);
|
|
37408
37424
|
};
|
|
37409
|
-
const getDetail = (key) => {
|
|
37425
|
+
const getDetail$1 = (key) => {
|
|
37410
37426
|
// Handle the scenario where detail is a falsy value
|
|
37411
37427
|
if (RUNTIME_DETAILS[key] === undefined) {
|
|
37412
37428
|
return undefined;
|
|
@@ -37438,7 +37454,7 @@ const flattenProperties = (properties) => {
|
|
|
37438
37454
|
};
|
|
37439
37455
|
|
|
37440
37456
|
// WARNING: DO NOT CHANGE THE STRING BELOW. IT GETS REPLACED AT BUILD TIME.
|
|
37441
|
-
const SDK_VERSION = '1.7.
|
|
37457
|
+
const SDK_VERSION = '1.7.3';
|
|
37442
37458
|
const getReferrer = () => {
|
|
37443
37459
|
if (isNode()) {
|
|
37444
37460
|
return '';
|
|
@@ -37481,7 +37497,7 @@ const initialise = async () => {
|
|
|
37481
37497
|
initialised = true;
|
|
37482
37498
|
try {
|
|
37483
37499
|
const runtimeDetails = flattenProperties(getRuntimeDetails());
|
|
37484
|
-
const existingRuntimeId = getDetail(Detail.RUNTIME_ID);
|
|
37500
|
+
const existingRuntimeId = getDetail$1(Detail.RUNTIME_ID);
|
|
37485
37501
|
const body = {
|
|
37486
37502
|
version: 1,
|
|
37487
37503
|
data: {
|
|
@@ -37613,6 +37629,7 @@ const setPublishableApiKeyFn = (publishableApiKey) => {
|
|
|
37613
37629
|
storeDetail(Detail.PUBLISHABLE_API_KEY, publishableApiKey);
|
|
37614
37630
|
};
|
|
37615
37631
|
errorBoundary(getGlobalisedValue('setPublishableApiKey', setPublishableApiKeyFn));
|
|
37632
|
+
errorBoundary(getGlobalisedValue('getDetail', getDetail$1));
|
|
37616
37633
|
|
|
37617
37634
|
var Environment;
|
|
37618
37635
|
(function (Environment) {
|
|
@@ -42605,7 +42622,7 @@ const IMMUTABLE_ZKVEM_GAS_OVERRIDES = {
|
|
|
42605
42622
|
maxPriorityFeePerGas: ethers.BigNumber.from(10e9),
|
|
42606
42623
|
};
|
|
42607
42624
|
|
|
42608
|
-
const SDK_VERSION_MARKER = '1.7.
|
|
42625
|
+
const SDK_VERSION_MARKER = '1.7.3';
|
|
42609
42626
|
// This SDK version is replaced by the `yarn build` command ran on the root level
|
|
42610
42627
|
const globalPackageVersion = () => SDK_VERSION_MARKER;
|
|
42611
42628
|
|
package/dist/index.d.ts
CHANGED
|
@@ -12630,51 +12630,51 @@ interface MetadataRefreshRateLimitResult$1 {
|
|
|
12630
12630
|
/**
|
|
12631
12631
|
*
|
|
12632
12632
|
* @export
|
|
12633
|
-
* @interface
|
|
12633
|
+
* @interface NFTMetadataRequest
|
|
12634
12634
|
*/
|
|
12635
|
-
interface
|
|
12635
|
+
interface NFTMetadataRequest$1 {
|
|
12636
12636
|
/**
|
|
12637
12637
|
* The name of the NFT
|
|
12638
12638
|
* @type {string}
|
|
12639
|
-
* @memberof
|
|
12639
|
+
* @memberof NFTMetadataRequest
|
|
12640
12640
|
*/
|
|
12641
|
-
'name'
|
|
12641
|
+
'name'?: string | null;
|
|
12642
12642
|
/**
|
|
12643
12643
|
* The description of the NFT
|
|
12644
12644
|
* @type {string}
|
|
12645
|
-
* @memberof
|
|
12645
|
+
* @memberof NFTMetadataRequest
|
|
12646
12646
|
*/
|
|
12647
|
-
'description'
|
|
12647
|
+
'description'?: string | null;
|
|
12648
12648
|
/**
|
|
12649
12649
|
* The image url of the NFT
|
|
12650
12650
|
* @type {string}
|
|
12651
|
-
* @memberof
|
|
12651
|
+
* @memberof NFTMetadataRequest
|
|
12652
12652
|
*/
|
|
12653
|
-
'image'
|
|
12653
|
+
'image'?: string | null;
|
|
12654
12654
|
/**
|
|
12655
12655
|
* The external link of the NFT
|
|
12656
12656
|
* @type {string}
|
|
12657
|
-
* @memberof
|
|
12657
|
+
* @memberof NFTMetadataRequest
|
|
12658
12658
|
*/
|
|
12659
|
-
'external_url'
|
|
12659
|
+
'external_url'?: string | null;
|
|
12660
12660
|
/**
|
|
12661
12661
|
* The animation url of the NFT
|
|
12662
12662
|
* @type {string}
|
|
12663
|
-
* @memberof
|
|
12663
|
+
* @memberof NFTMetadataRequest
|
|
12664
12664
|
*/
|
|
12665
|
-
'animation_url'
|
|
12665
|
+
'animation_url'?: string | null;
|
|
12666
12666
|
/**
|
|
12667
12667
|
* The youtube link of the NFT
|
|
12668
12668
|
* @type {string}
|
|
12669
|
-
* @memberof
|
|
12669
|
+
* @memberof NFTMetadataRequest
|
|
12670
12670
|
*/
|
|
12671
|
-
'youtube_url'
|
|
12671
|
+
'youtube_url'?: string | null;
|
|
12672
12672
|
/**
|
|
12673
12673
|
* List of Metadata attributes
|
|
12674
12674
|
* @type {Array<NFTMetadataAttribute>}
|
|
12675
|
-
* @memberof
|
|
12675
|
+
* @memberof NFTMetadataRequest
|
|
12676
12676
|
*/
|
|
12677
|
-
'attributes'
|
|
12677
|
+
'attributes'?: Array<NFTMetadataAttribute$1> | null;
|
|
12678
12678
|
}
|
|
12679
12679
|
|
|
12680
12680
|
/**
|
|
@@ -12766,6 +12766,24 @@ interface RefreshMetadataByIDAllOf$1 {
|
|
|
12766
12766
|
'metadata_id': string;
|
|
12767
12767
|
}
|
|
12768
12768
|
|
|
12769
|
+
/**
|
|
12770
|
+
* Immutable zkEVM API
|
|
12771
|
+
* Immutable Multi Rollup API
|
|
12772
|
+
*
|
|
12773
|
+
* The version of the OpenAPI document: 1.0.0
|
|
12774
|
+
* Contact: support@immutable.com
|
|
12775
|
+
*
|
|
12776
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
12777
|
+
* https://openapi-generator.tech
|
|
12778
|
+
* Do not edit the class manually.
|
|
12779
|
+
*/
|
|
12780
|
+
|
|
12781
|
+
/**
|
|
12782
|
+
* @type RefreshableNFTAttributes
|
|
12783
|
+
* @export
|
|
12784
|
+
*/
|
|
12785
|
+
type RefreshableNFTAttributes$1 = NFTMetadataRequest$1;
|
|
12786
|
+
|
|
12769
12787
|
/**
|
|
12770
12788
|
* Immutable zkEVM API
|
|
12771
12789
|
* Immutable Multi Rollup API
|
|
@@ -15361,6 +15379,12 @@ interface GetMintRequestResult {
|
|
|
15361
15379
|
* @memberof GetMintRequestResult
|
|
15362
15380
|
*/
|
|
15363
15381
|
'token_id': string | null;
|
|
15382
|
+
/**
|
|
15383
|
+
* The id of the mint activity associated with this mint request
|
|
15384
|
+
* @type {string}
|
|
15385
|
+
* @memberof GetMintRequestResult
|
|
15386
|
+
*/
|
|
15387
|
+
'activity_id'?: string | null;
|
|
15364
15388
|
/**
|
|
15365
15389
|
* The transaction hash of the activity
|
|
15366
15390
|
* @type {string}
|
|
@@ -16289,51 +16313,51 @@ interface MetadataRefreshRateLimitResult {
|
|
|
16289
16313
|
/**
|
|
16290
16314
|
*
|
|
16291
16315
|
* @export
|
|
16292
|
-
* @interface
|
|
16316
|
+
* @interface NFTMetadataRequest
|
|
16293
16317
|
*/
|
|
16294
|
-
interface
|
|
16318
|
+
interface NFTMetadataRequest {
|
|
16295
16319
|
/**
|
|
16296
16320
|
* The name of the NFT
|
|
16297
16321
|
* @type {string}
|
|
16298
|
-
* @memberof
|
|
16322
|
+
* @memberof NFTMetadataRequest
|
|
16299
16323
|
*/
|
|
16300
|
-
'name'
|
|
16324
|
+
'name'?: string | null;
|
|
16301
16325
|
/**
|
|
16302
16326
|
* The description of the NFT
|
|
16303
16327
|
* @type {string}
|
|
16304
|
-
* @memberof
|
|
16328
|
+
* @memberof NFTMetadataRequest
|
|
16305
16329
|
*/
|
|
16306
|
-
'description'
|
|
16330
|
+
'description'?: string | null;
|
|
16307
16331
|
/**
|
|
16308
16332
|
* The image url of the NFT
|
|
16309
16333
|
* @type {string}
|
|
16310
|
-
* @memberof
|
|
16334
|
+
* @memberof NFTMetadataRequest
|
|
16311
16335
|
*/
|
|
16312
|
-
'image'
|
|
16336
|
+
'image'?: string | null;
|
|
16313
16337
|
/**
|
|
16314
16338
|
* The external link of the NFT
|
|
16315
16339
|
* @type {string}
|
|
16316
|
-
* @memberof
|
|
16340
|
+
* @memberof NFTMetadataRequest
|
|
16317
16341
|
*/
|
|
16318
|
-
'external_url'
|
|
16342
|
+
'external_url'?: string | null;
|
|
16319
16343
|
/**
|
|
16320
16344
|
* The animation url of the NFT
|
|
16321
16345
|
* @type {string}
|
|
16322
|
-
* @memberof
|
|
16346
|
+
* @memberof NFTMetadataRequest
|
|
16323
16347
|
*/
|
|
16324
|
-
'animation_url'
|
|
16348
|
+
'animation_url'?: string | null;
|
|
16325
16349
|
/**
|
|
16326
16350
|
* The youtube link of the NFT
|
|
16327
16351
|
* @type {string}
|
|
16328
|
-
* @memberof
|
|
16352
|
+
* @memberof NFTMetadataRequest
|
|
16329
16353
|
*/
|
|
16330
|
-
'youtube_url'
|
|
16354
|
+
'youtube_url'?: string | null;
|
|
16331
16355
|
/**
|
|
16332
16356
|
* List of Metadata attributes
|
|
16333
16357
|
* @type {Array<NFTMetadataAttribute>}
|
|
16334
|
-
* @memberof
|
|
16358
|
+
* @memberof NFTMetadataRequest
|
|
16335
16359
|
*/
|
|
16336
|
-
'attributes'
|
|
16360
|
+
'attributes'?: Array<NFTMetadataAttribute> | null;
|
|
16337
16361
|
}
|
|
16338
16362
|
|
|
16339
16363
|
/**
|
|
@@ -16368,10 +16392,10 @@ interface MintAsset {
|
|
|
16368
16392
|
'owner_address': string;
|
|
16369
16393
|
/**
|
|
16370
16394
|
*
|
|
16371
|
-
* @type {
|
|
16395
|
+
* @type {NFTMetadataRequest}
|
|
16372
16396
|
* @memberof MintAsset
|
|
16373
16397
|
*/
|
|
16374
|
-
'metadata'?:
|
|
16398
|
+
'metadata'?: NFTMetadataRequest;
|
|
16375
16399
|
}
|
|
16376
16400
|
|
|
16377
16401
|
/**
|
|
@@ -16463,6 +16487,24 @@ interface RefreshMetadataByIDAllOf {
|
|
|
16463
16487
|
'metadata_id': string;
|
|
16464
16488
|
}
|
|
16465
16489
|
|
|
16490
|
+
/**
|
|
16491
|
+
* Immutable zkEVM API
|
|
16492
|
+
* Immutable Multi Rollup API
|
|
16493
|
+
*
|
|
16494
|
+
* The version of the OpenAPI document: 1.0.0
|
|
16495
|
+
* Contact: support@immutable.com
|
|
16496
|
+
*
|
|
16497
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
16498
|
+
* https://openapi-generator.tech
|
|
16499
|
+
* Do not edit the class manually.
|
|
16500
|
+
*/
|
|
16501
|
+
|
|
16502
|
+
/**
|
|
16503
|
+
* @type RefreshableNFTAttributes
|
|
16504
|
+
* @export
|
|
16505
|
+
*/
|
|
16506
|
+
type RefreshableNFTAttributes = NFTMetadataRequest;
|
|
16507
|
+
|
|
16466
16508
|
/**
|
|
16467
16509
|
* Immutable zkEVM API
|
|
16468
16510
|
* Immutable Multi Rollup API
|
|
@@ -17456,6 +17498,7 @@ type index_d_NFTContractType = NFTContractType;
|
|
|
17456
17498
|
declare const index_d_NFTContractType: typeof NFTContractType;
|
|
17457
17499
|
type index_d_NFTMetadataAttribute = NFTMetadataAttribute;
|
|
17458
17500
|
type index_d_NFTMetadataAttributeValue = NFTMetadataAttributeValue;
|
|
17501
|
+
type index_d_NFTMetadataRequest = NFTMetadataRequest;
|
|
17459
17502
|
type index_d_NFTOwner = NFTOwner;
|
|
17460
17503
|
type index_d_NFTSale = NFTSale;
|
|
17461
17504
|
type index_d_NFTWithBalance = NFTWithBalance;
|
|
@@ -17574,6 +17617,7 @@ declare namespace index_d {
|
|
|
17574
17617
|
index_d_NFTContractType as NFTContractType,
|
|
17575
17618
|
index_d_NFTMetadataAttribute as NFTMetadataAttribute,
|
|
17576
17619
|
index_d_NFTMetadataAttributeValue as NFTMetadataAttributeValue,
|
|
17620
|
+
index_d_NFTMetadataRequest as NFTMetadataRequest,
|
|
17577
17621
|
index_d_NFTOwner as NFTOwner,
|
|
17578
17622
|
index_d_NFTSale as NFTSale,
|
|
17579
17623
|
index_d_NFTWithBalance as NFTWithBalance,
|
|
@@ -30822,6 +30866,7 @@ interface CheckoutModuleConfiguration extends ModuleConfiguration<CheckoutOverri
|
|
|
30822
30866
|
/**
|
|
30823
30867
|
* A type representing various remotely defined configurations which are
|
|
30824
30868
|
* accessible via the Checkout config and configured based on the Environment.
|
|
30869
|
+
* @property {ConnectConfig} connect
|
|
30825
30870
|
* @property {DexConfig} dex
|
|
30826
30871
|
* @property {OnRampConfig} onramp
|
|
30827
30872
|
* @property {BridgeConfig} bridge
|
|
@@ -30831,6 +30876,8 @@ interface CheckoutModuleConfiguration extends ModuleConfiguration<CheckoutOverri
|
|
|
30831
30876
|
* @property {TelemetryConfig | undefined} telemetry
|
|
30832
30877
|
*/
|
|
30833
30878
|
type RemoteConfiguration = {
|
|
30879
|
+
/** The config used for the Connect. */
|
|
30880
|
+
connect: ConnectConfig;
|
|
30834
30881
|
/** The config used for the DEX. */
|
|
30835
30882
|
dex: DexConfig;
|
|
30836
30883
|
/** The config used for the OnRamp */
|
|
@@ -30882,6 +30929,14 @@ type OnRampConfig = {
|
|
|
30882
30929
|
/** OnRamp config for Transak provider */
|
|
30883
30930
|
[key: string]: OnRampProviderConfig;
|
|
30884
30931
|
};
|
|
30932
|
+
/**
|
|
30933
|
+
* A type representing the configuration for the Connect.
|
|
30934
|
+
* @property {boolean} walletConnect
|
|
30935
|
+
*/
|
|
30936
|
+
type ConnectConfig = {
|
|
30937
|
+
/** A boolean value for enabling/disabling WalletConnect */
|
|
30938
|
+
walletConnect: boolean;
|
|
30939
|
+
};
|
|
30885
30940
|
/**
|
|
30886
30941
|
* A type representing the configuration for the DEX.
|
|
30887
30942
|
* @property {ExchangeOverrides | undefined} overrides
|
package/dist/index.js
CHANGED
|
@@ -120,7 +120,7 @@ const storeDetail$1 = (key, value) => {
|
|
|
120
120
|
};
|
|
121
121
|
setItem$1(Store$1.RUNTIME, RUNTIME_DETAILS$1);
|
|
122
122
|
};
|
|
123
|
-
const getDetail$1 = (key) => {
|
|
123
|
+
const getDetail$1$1 = (key) => {
|
|
124
124
|
// Handle the scenario where detail is a falsy value
|
|
125
125
|
if (RUNTIME_DETAILS$1[key] === undefined) {
|
|
126
126
|
return undefined;
|
|
@@ -152,7 +152,7 @@ const flattenProperties$1 = (properties) => {
|
|
|
152
152
|
};
|
|
153
153
|
|
|
154
154
|
// WARNING: DO NOT CHANGE THE STRING BELOW. IT GETS REPLACED AT BUILD TIME.
|
|
155
|
-
const SDK_VERSION$1 = '1.7.
|
|
155
|
+
const SDK_VERSION$1 = '1.7.3';
|
|
156
156
|
const getReferrer$1 = () => {
|
|
157
157
|
if (isNode$1()) {
|
|
158
158
|
return '';
|
|
@@ -195,7 +195,7 @@ const initialise$2 = async () => {
|
|
|
195
195
|
initialised$1 = true;
|
|
196
196
|
try {
|
|
197
197
|
const runtimeDetails = flattenProperties$1(getRuntimeDetails$1());
|
|
198
|
-
const existingRuntimeId = getDetail$1(Detail$1.RUNTIME_ID);
|
|
198
|
+
const existingRuntimeId = getDetail$1$1(Detail$1.RUNTIME_ID);
|
|
199
199
|
const body = {
|
|
200
200
|
version: 1,
|
|
201
201
|
data: {
|
|
@@ -348,6 +348,7 @@ const setPublishableApiKeyFn$1 = (publishableApiKey) => {
|
|
|
348
348
|
storeDetail$1(Detail$1.PUBLISHABLE_API_KEY, publishableApiKey);
|
|
349
349
|
};
|
|
350
350
|
const setPublishableApiKey = errorBoundary$1(getGlobalisedValue$2('setPublishableApiKey', setPublishableApiKeyFn$1));
|
|
351
|
+
const getDetail = errorBoundary$1(getGlobalisedValue$2('getDetail', getDetail$1$1));
|
|
351
352
|
|
|
352
353
|
var Environment$1;
|
|
353
354
|
(function (Environment) {
|
|
@@ -11275,7 +11276,7 @@ class MultiRollupApiClients {
|
|
|
11275
11276
|
}
|
|
11276
11277
|
|
|
11277
11278
|
// eslint-disable-next-line @typescript-eslint/naming-convention
|
|
11278
|
-
const defaultHeaders$1 = { 'x-sdk-version': 'ts-immutable-sdk-1.7.
|
|
11279
|
+
const defaultHeaders$1 = { 'x-sdk-version': 'ts-immutable-sdk-1.7.3' };
|
|
11279
11280
|
const createConfig = ({ basePath, headers, }) => {
|
|
11280
11281
|
if (!basePath.trim()) {
|
|
11281
11282
|
throw Error('basePath can not be empty');
|
|
@@ -11347,7 +11348,7 @@ class APIError extends Error {
|
|
|
11347
11348
|
|
|
11348
11349
|
/* eslint-disable implicit-arrow-linebreak */
|
|
11349
11350
|
const defaultHeaders = {
|
|
11350
|
-
sdkVersion: 'ts-immutable-sdk-multi-rollup-api-client-1.7.
|
|
11351
|
+
sdkVersion: 'ts-immutable-sdk-multi-rollup-api-client-1.7.3',
|
|
11351
11352
|
};
|
|
11352
11353
|
/**
|
|
11353
11354
|
* createAPIConfiguration to create a custom Configuration
|
|
@@ -11780,7 +11781,7 @@ const createImmutableXConfiguration = ({ basePath, chainID, coreContractAddress,
|
|
|
11780
11781
|
chainID,
|
|
11781
11782
|
coreContractAddress,
|
|
11782
11783
|
registrationContractAddress,
|
|
11783
|
-
sdkVersion: 'ts-immutable-sdk-1.7.
|
|
11784
|
+
sdkVersion: 'ts-immutable-sdk-1.7.3',
|
|
11784
11785
|
});
|
|
11785
11786
|
/**
|
|
11786
11787
|
* Sets `sdkVersion` at the time of build
|
|
@@ -16514,10 +16515,20 @@ class AuthManager {
|
|
|
16514
16515
|
},
|
|
16515
16516
|
});
|
|
16516
16517
|
};
|
|
16517
|
-
|
|
16518
|
+
/**
|
|
16519
|
+
* login
|
|
16520
|
+
* @param anonymousId Caller can pass an anonymousId if they want to associate their user's identity with immutable's internal instrumentation.
|
|
16521
|
+
*/
|
|
16522
|
+
async login(anonymousId) {
|
|
16518
16523
|
return withPassportError(async () => {
|
|
16524
|
+
const rid = getDetail(Detail$1.RUNTIME_ID);
|
|
16519
16525
|
const popupWindowFeatures = { width: 410, height: 450 };
|
|
16520
16526
|
const oidcUser = await this.userManager.signinPopup({
|
|
16527
|
+
extraQueryParams: {
|
|
16528
|
+
...(this.userManager.settings?.extraQueryParams ?? {}),
|
|
16529
|
+
rid: rid || '',
|
|
16530
|
+
third_party_a_id: anonymousId || '',
|
|
16531
|
+
},
|
|
16521
16532
|
popupWindowFeatures,
|
|
16522
16533
|
});
|
|
16523
16534
|
return AuthManager.mapOidcUserToDomainModel(oidcUser);
|
|
@@ -16537,17 +16548,22 @@ class AuthManager {
|
|
|
16537
16548
|
async loginCallback() {
|
|
16538
16549
|
return withPassportError(async () => this.userManager.signinPopupCallback(), PassportErrorType.AUTHENTICATION_ERROR);
|
|
16539
16550
|
}
|
|
16540
|
-
|
|
16551
|
+
/**
|
|
16552
|
+
* loginWithDeviceFlow
|
|
16553
|
+
* @param anonymousId Caller can pass an anonymousId if they want to associate their user's identity with immutable's internal instrumentation.
|
|
16554
|
+
*/
|
|
16555
|
+
async loginWithDeviceFlow(anonymousId) {
|
|
16541
16556
|
return withPassportError(async () => {
|
|
16542
16557
|
const response = await globalAxios$1.post(`${this.config.authenticationDomain}/oauth/device/code`, {
|
|
16543
16558
|
client_id: this.config.oidcConfiguration.clientId,
|
|
16544
16559
|
scope: this.config.oidcConfiguration.scope,
|
|
16545
16560
|
audience: this.config.oidcConfiguration.audience,
|
|
16546
16561
|
}, formUrlEncodedHeader);
|
|
16562
|
+
const rid = getDetail(Detail$1.RUNTIME_ID);
|
|
16547
16563
|
return {
|
|
16548
16564
|
code: response.data.user_code,
|
|
16549
16565
|
deviceCode: response.data.device_code,
|
|
16550
|
-
url: response.data.verification_uri_complete
|
|
16566
|
+
url: `${response.data.verification_uri_complete}${rid ? `&rid=${rid}` : ''}${anonymousId ? `&third_party_a_id=${anonymousId}` : ''}`,
|
|
16551
16567
|
interval: response.data.interval,
|
|
16552
16568
|
};
|
|
16553
16569
|
}, PassportErrorType.AUTHENTICATION_ERROR);
|
|
@@ -37384,7 +37400,7 @@ const storeDetail = (key, value) => {
|
|
|
37384
37400
|
};
|
|
37385
37401
|
setItem(Store.RUNTIME, RUNTIME_DETAILS);
|
|
37386
37402
|
};
|
|
37387
|
-
const getDetail = (key) => {
|
|
37403
|
+
const getDetail$1 = (key) => {
|
|
37388
37404
|
// Handle the scenario where detail is a falsy value
|
|
37389
37405
|
if (RUNTIME_DETAILS[key] === undefined) {
|
|
37390
37406
|
return undefined;
|
|
@@ -37416,7 +37432,7 @@ const flattenProperties = (properties) => {
|
|
|
37416
37432
|
};
|
|
37417
37433
|
|
|
37418
37434
|
// WARNING: DO NOT CHANGE THE STRING BELOW. IT GETS REPLACED AT BUILD TIME.
|
|
37419
|
-
const SDK_VERSION = '1.7.
|
|
37435
|
+
const SDK_VERSION = '1.7.3';
|
|
37420
37436
|
const getReferrer = () => {
|
|
37421
37437
|
if (isNode()) {
|
|
37422
37438
|
return '';
|
|
@@ -37459,7 +37475,7 @@ const initialise = async () => {
|
|
|
37459
37475
|
initialised = true;
|
|
37460
37476
|
try {
|
|
37461
37477
|
const runtimeDetails = flattenProperties(getRuntimeDetails());
|
|
37462
|
-
const existingRuntimeId = getDetail(Detail.RUNTIME_ID);
|
|
37478
|
+
const existingRuntimeId = getDetail$1(Detail.RUNTIME_ID);
|
|
37463
37479
|
const body = {
|
|
37464
37480
|
version: 1,
|
|
37465
37481
|
data: {
|
|
@@ -37591,6 +37607,7 @@ const setPublishableApiKeyFn = (publishableApiKey) => {
|
|
|
37591
37607
|
storeDetail(Detail.PUBLISHABLE_API_KEY, publishableApiKey);
|
|
37592
37608
|
};
|
|
37593
37609
|
errorBoundary(getGlobalisedValue('setPublishableApiKey', setPublishableApiKeyFn));
|
|
37610
|
+
errorBoundary(getGlobalisedValue('getDetail', getDetail$1));
|
|
37594
37611
|
|
|
37595
37612
|
var Environment;
|
|
37596
37613
|
(function (Environment) {
|
|
@@ -42583,7 +42600,7 @@ const IMMUTABLE_ZKVEM_GAS_OVERRIDES = {
|
|
|
42583
42600
|
maxPriorityFeePerGas: BigNumber$1.from(10e9),
|
|
42584
42601
|
};
|
|
42585
42602
|
|
|
42586
|
-
const SDK_VERSION_MARKER = '1.7.
|
|
42603
|
+
const SDK_VERSION_MARKER = '1.7.3';
|
|
42587
42604
|
// This SDK version is replaced by the `yarn build` command ran on the root level
|
|
42588
42605
|
const globalPackageVersion = () => SDK_VERSION_MARKER;
|
|
42589
42606
|
|
package/dist/orderbook.js
CHANGED
|
@@ -99,7 +99,7 @@ const storeDetail = (key, value) => {
|
|
|
99
99
|
};
|
|
100
100
|
setItem(Store.RUNTIME, RUNTIME_DETAILS);
|
|
101
101
|
};
|
|
102
|
-
const getDetail = (key) => {
|
|
102
|
+
const getDetail$1 = (key) => {
|
|
103
103
|
// Handle the scenario where detail is a falsy value
|
|
104
104
|
if (RUNTIME_DETAILS[key] === undefined) {
|
|
105
105
|
return undefined;
|
|
@@ -131,7 +131,7 @@ const flattenProperties = (properties) => {
|
|
|
131
131
|
};
|
|
132
132
|
|
|
133
133
|
// WARNING: DO NOT CHANGE THE STRING BELOW. IT GETS REPLACED AT BUILD TIME.
|
|
134
|
-
const SDK_VERSION = '1.7.
|
|
134
|
+
const SDK_VERSION = '1.7.3';
|
|
135
135
|
const getReferrer = () => {
|
|
136
136
|
if (isNode()) {
|
|
137
137
|
return '';
|
|
@@ -174,7 +174,7 @@ const initialise = async () => {
|
|
|
174
174
|
initialised = true;
|
|
175
175
|
try {
|
|
176
176
|
const runtimeDetails = flattenProperties(getRuntimeDetails());
|
|
177
|
-
const existingRuntimeId = getDetail(Detail.RUNTIME_ID);
|
|
177
|
+
const existingRuntimeId = getDetail$1(Detail.RUNTIME_ID);
|
|
178
178
|
const body = {
|
|
179
179
|
version: 1,
|
|
180
180
|
data: {
|
|
@@ -306,6 +306,7 @@ const setPublishableApiKeyFn = (publishableApiKey) => {
|
|
|
306
306
|
storeDetail(Detail.PUBLISHABLE_API_KEY, publishableApiKey);
|
|
307
307
|
};
|
|
308
308
|
errorBoundary(getGlobalisedValue('setPublishableApiKey', setPublishableApiKeyFn));
|
|
309
|
+
errorBoundary(getGlobalisedValue('getDetail', getDetail$1));
|
|
309
310
|
|
|
310
311
|
var Environment;
|
|
311
312
|
(function (Environment) {
|