@near-mobile/connector 0.0.1 → 0.0.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/{chunk-ZSGMXHWO.js → chunk-7VPD5BML.js} +1 -1
- package/dist/{chunk-JNEY2ZRQ.mjs → chunk-APKMGRUO.mjs} +1 -1
- package/dist/{chunk-IJX4BI6K.mjs → chunk-B2YNUFH6.mjs} +2 -2
- package/dist/{chunk-FL7KKCCZ.mjs → chunk-GIXEEREC.mjs} +1 -1
- package/dist/{chunk-ZTA2C53I.js → chunk-HVMVKTGG.js} +2 -2
- package/dist/{chunk-LFZIFHVN.js → chunk-JLBRCZBF.js} +4 -4
- package/dist/{chunk-AVS7JT4Z.mjs → chunk-L2EA5E7P.mjs} +2 -2
- package/dist/{chunk-HFA6CLHG.js → chunk-NCPQ2YHO.js} +3 -3
- package/dist/{chunk-TNOFKWGZ.mjs → chunk-OWBUUQRE.mjs} +1 -1
- package/dist/{chunk-BUPQ5TK7.js → chunk-ZZJKEHX6.js} +3 -3
- package/dist/config.js +2 -2
- package/dist/config.mjs +1 -1
- package/dist/connector.js +3 -3
- package/dist/connector.mjs +2 -2
- package/dist/index.d.mts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +4 -4
- package/dist/index.mjs +3 -3
- package/dist/main.d.mts +1 -1
- package/dist/main.d.ts +1 -1
- package/dist/main.js +6 -6
- package/dist/main.mjs +5 -5
- package/dist/strategies/qr-code/index.js +5 -5
- package/dist/strategies/qr-code/index.mjs +4 -4
- package/dist/strategies/qr-code/qr-code.config.js +2 -2
- package/dist/strategies/qr-code/qr-code.config.mjs +1 -1
- package/dist/strategies/qr-code/qr-code.js +5 -5
- package/dist/strategies/qr-code/qr-code.mjs +4 -4
- package/dist/types.d.mts +114 -19
- package/dist/types.d.ts +114 -19
- package/dist/utils.js +3 -3
- package/dist/utils.mjs +2 -2
- package/package.json +12 -17
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});// src/config.ts
|
|
2
2
|
var nearMobileConnectorConfig = {
|
|
3
|
-
apiUrl: "https://near-mobile-production.aws.peersyst.tech
|
|
3
|
+
apiUrl: "https://near-mobile-production.aws.peersyst.tech",
|
|
4
4
|
mobileRequestUrl: "near-mobile-wallet://connector-request?id={id}",
|
|
5
5
|
universalRequestUrl: "https://near-mobile-production.aws.peersyst.tech/api/deep-link?path=connector-request¶ms=id%3D{id}",
|
|
6
6
|
responsePolling: {
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import {
|
|
2
2
|
buildNearMobileAppRequestUrl
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-GIXEEREC.mjs";
|
|
4
4
|
import {
|
|
5
5
|
qrCodeConfig
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-L2EA5E7P.mjs";
|
|
7
7
|
|
|
8
8
|
// src/strategies/qr-code/qr-code.ts
|
|
9
9
|
import QRCodeStyling from "qr-code-styling";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});// src/strategies/qr-code/qr-code.config.ts
|
|
2
2
|
var qrCodeConfig = {
|
|
3
|
-
width:
|
|
4
|
-
height:
|
|
3
|
+
width: 160,
|
|
4
|
+
height: 160,
|
|
5
5
|
type: "svg",
|
|
6
6
|
image: "https://near-mobile-production.aws.peersyst.tech/connector/near-mobile-qr-logo.svg",
|
|
7
7
|
dotsOptions: {
|
|
@@ -1,21 +1,21 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var _chunkNCPQ2YHOjs = require('./chunk-NCPQ2YHO.js');
|
|
4
4
|
|
|
5
5
|
|
|
6
|
-
var
|
|
6
|
+
var _chunkHVMVKTGGjs = require('./chunk-HVMVKTGG.js');
|
|
7
7
|
|
|
8
8
|
// src/strategies/qr-code/qr-code.ts
|
|
9
9
|
var _qrcodestyling = require('qr-code-styling'); var _qrcodestyling2 = _interopRequireDefault(_qrcodestyling);
|
|
10
10
|
var NearMobileQrCode = class extends _qrcodestyling2.default {
|
|
11
11
|
constructor({ requestId, ...restOptions }) {
|
|
12
|
-
const { image, imageOptions, ...restQrCodeConfig } =
|
|
12
|
+
const { image, imageOptions, ...restQrCodeConfig } = _chunkHVMVKTGGjs.qrCodeConfig;
|
|
13
13
|
super({
|
|
14
14
|
...restQrCodeConfig,
|
|
15
15
|
...restOptions,
|
|
16
16
|
image,
|
|
17
17
|
imageOptions,
|
|
18
|
-
data:
|
|
18
|
+
data: _chunkNCPQ2YHOjs.buildNearMobileAppRequestUrl.call(void 0, requestId)
|
|
19
19
|
});
|
|
20
20
|
}
|
|
21
21
|
};
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var _chunk7VPD5BMLjs = require('./chunk-7VPD5BML.js');
|
|
4
4
|
|
|
5
5
|
// src/utils.ts
|
|
6
6
|
function buildNearMobileAppRequestUrl(id) {
|
|
7
|
-
return
|
|
7
|
+
return _chunk7VPD5BMLjs.nearMobileConnectorConfig.mobileRequestUrl.replace("{id}", id);
|
|
8
8
|
}
|
|
9
9
|
function buildNearMobileUniversalRequestUrl(id) {
|
|
10
|
-
return
|
|
10
|
+
return _chunk7VPD5BMLjs.nearMobileConnectorConfig.universalRequestUrl.replace("{id}", id);
|
|
11
11
|
}
|
|
12
12
|
|
|
13
13
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// src/config.ts
|
|
2
2
|
var nearMobileConnectorConfig = {
|
|
3
|
-
apiUrl: "https://near-mobile-production.aws.peersyst.tech
|
|
3
|
+
apiUrl: "https://near-mobile-production.aws.peersyst.tech",
|
|
4
4
|
mobileRequestUrl: "near-mobile-wallet://connector-request?id={id}",
|
|
5
5
|
universalRequestUrl: "https://near-mobile-production.aws.peersyst.tech/api/deep-link?path=connector-request¶ms=id%3D{id}",
|
|
6
6
|
responsePolling: {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } } function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; }
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var _chunk7VPD5BMLjs = require('./chunk-7VPD5BML.js');
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
var _chunkMLKGABMKjs = require('./chunk-MLKGABMK.js');
|
|
@@ -483,12 +483,12 @@ function polling(fn, condition, options = {}) {
|
|
|
483
483
|
}
|
|
484
484
|
|
|
485
485
|
// src/connector.ts
|
|
486
|
-
OpenAPI.BASE =
|
|
486
|
+
OpenAPI.BASE = _chunk7VPD5BMLjs.nearMobileConnectorConfig.apiUrl;
|
|
487
487
|
var createRequest = RequestApi.createRequest;
|
|
488
488
|
var getRequest = RequestApi.getRequest;
|
|
489
489
|
function pollResponse(id, options = {}) {
|
|
490
490
|
const mergedOptions = {
|
|
491
|
-
...
|
|
491
|
+
..._chunk7VPD5BMLjs.nearMobileConnectorConfig.responsePolling,
|
|
492
492
|
...options
|
|
493
493
|
};
|
|
494
494
|
return polling(
|
package/dist/config.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var _chunk7VPD5BMLjs = require('./chunk-7VPD5BML.js');
|
|
4
4
|
require('./chunk-MLKGABMK.js');
|
|
5
5
|
|
|
6
6
|
|
|
7
|
-
exports.nearMobileConnectorConfig =
|
|
7
|
+
exports.nearMobileConnectorConfig = _chunk7VPD5BMLjs.nearMobileConnectorConfig;
|
package/dist/config.mjs
CHANGED
package/dist/connector.js
CHANGED
|
@@ -2,11 +2,11 @@
|
|
|
2
2
|
|
|
3
3
|
|
|
4
4
|
|
|
5
|
-
var
|
|
6
|
-
require('./chunk-
|
|
5
|
+
var _chunkZZJKEHX6js = require('./chunk-ZZJKEHX6.js');
|
|
6
|
+
require('./chunk-7VPD5BML.js');
|
|
7
7
|
require('./chunk-MLKGABMK.js');
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
|
|
11
11
|
|
|
12
|
-
exports.createRequest =
|
|
12
|
+
exports.createRequest = _chunkZZJKEHX6js.createRequest; exports.getRequest = _chunkZZJKEHX6js.getRequest; exports.pollResponse = _chunkZZJKEHX6js.pollResponse;
|
package/dist/connector.mjs
CHANGED
package/dist/index.d.mts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
export { c as NearMobileConnector } from './connector-k1ZUc4Z5.mjs';
|
|
2
2
|
export { buildNearMobileAppRequestUrl, buildNearMobileUniversalRequestUrl } from './utils.mjs';
|
|
3
|
-
export { ConnectorRequestDto, ConnectorRequestRequest, ConnectorRequestResponseRequest, ConnectorSignAndSendTransactionPayloadDto, ConnectorSignAndSendTransactionPayloadRequest, ConnectorSignAndSendTransactionsPayloadDto, ConnectorSignAndSendTransactionsPayloadRequest,
|
|
3
|
+
export { AllowMethodsAllDto, AllowMethodsAllParams, AllowMethodsSelectDto, AllowMethodsSelectParams, ConnectorActionDto, ConnectorActionRequest, ConnectorDelegateActionDto, ConnectorDelegateActionRequest, ConnectorRequestDto, ConnectorRequestRequest, ConnectorRequestResponseRequest, ConnectorSignAndSendTransactionPayloadDto, ConnectorSignAndSendTransactionPayloadRequest, ConnectorSignAndSendTransactionsPayloadDto, ConnectorSignAndSendTransactionsPayloadRequest, ConnectorSignDelegateActionsPayloadDto, ConnectorSignDelegateActionsPayloadRequest, ConnectorSignInAddFunctionCallKeyDto, ConnectorSignInAddFunctionCallKeyParams, ConnectorSignInAndSignMessageDto, ConnectorSignInAndSignMessageParams, ConnectorSignInResponseDto, ConnectorSignInWithKeyPayloadDto, ConnectorSignInWithKeyPayloadRequest, ConnectorSignInWithMessagePayloadDto, ConnectorSignInWithMessagePayloadRequest, ConnectorSignInWithMessageResponseDto, ConnectorSignMessagePayloadDto, ConnectorSignMessagePayloadRequest, ConnectorSignMessageResponseDto, ConnectorTransactionDto, ConnectorTransactionRequest, GasAllowanceLimitedDto, GasAllowanceLimitedParams, GasAllowanceUnlimitedDto, GasAllowanceUnlimitedParams, Polling, PollingOptions } from './types.mjs';
|
package/dist/index.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
export { c as NearMobileConnector } from './connector-o47KNKfA.js';
|
|
2
2
|
export { buildNearMobileAppRequestUrl, buildNearMobileUniversalRequestUrl } from './utils.js';
|
|
3
|
-
export { ConnectorRequestDto, ConnectorRequestRequest, ConnectorRequestResponseRequest, ConnectorSignAndSendTransactionPayloadDto, ConnectorSignAndSendTransactionPayloadRequest, ConnectorSignAndSendTransactionsPayloadDto, ConnectorSignAndSendTransactionsPayloadRequest,
|
|
3
|
+
export { AllowMethodsAllDto, AllowMethodsAllParams, AllowMethodsSelectDto, AllowMethodsSelectParams, ConnectorActionDto, ConnectorActionRequest, ConnectorDelegateActionDto, ConnectorDelegateActionRequest, ConnectorRequestDto, ConnectorRequestRequest, ConnectorRequestResponseRequest, ConnectorSignAndSendTransactionPayloadDto, ConnectorSignAndSendTransactionPayloadRequest, ConnectorSignAndSendTransactionsPayloadDto, ConnectorSignAndSendTransactionsPayloadRequest, ConnectorSignDelegateActionsPayloadDto, ConnectorSignDelegateActionsPayloadRequest, ConnectorSignInAddFunctionCallKeyDto, ConnectorSignInAddFunctionCallKeyParams, ConnectorSignInAndSignMessageDto, ConnectorSignInAndSignMessageParams, ConnectorSignInResponseDto, ConnectorSignInWithKeyPayloadDto, ConnectorSignInWithKeyPayloadRequest, ConnectorSignInWithMessagePayloadDto, ConnectorSignInWithMessagePayloadRequest, ConnectorSignInWithMessageResponseDto, ConnectorSignMessagePayloadDto, ConnectorSignMessagePayloadRequest, ConnectorSignMessageResponseDto, ConnectorTransactionDto, ConnectorTransactionRequest, GasAllowanceLimitedDto, GasAllowanceLimitedParams, GasAllowanceUnlimitedDto, GasAllowanceUnlimitedParams, Polling, PollingOptions } from './types.js';
|
package/dist/index.js
CHANGED
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});require('./chunk-6KQS7CTR.js');
|
|
2
2
|
|
|
3
3
|
|
|
4
|
-
var
|
|
4
|
+
var _chunkZZJKEHX6js = require('./chunk-ZZJKEHX6.js');
|
|
5
5
|
require('./chunk-6F4PWJZI.js');
|
|
6
6
|
|
|
7
7
|
|
|
8
8
|
|
|
9
|
-
var
|
|
10
|
-
require('./chunk-
|
|
9
|
+
var _chunkNCPQ2YHOjs = require('./chunk-NCPQ2YHO.js');
|
|
10
|
+
require('./chunk-7VPD5BML.js');
|
|
11
11
|
require('./chunk-MLKGABMK.js');
|
|
12
12
|
|
|
13
13
|
|
|
14
14
|
|
|
15
15
|
|
|
16
|
-
exports.NearMobileConnector =
|
|
16
|
+
exports.NearMobileConnector = _chunkZZJKEHX6js.connector_exports; exports.buildNearMobileAppRequestUrl = _chunkNCPQ2YHOjs.buildNearMobileAppRequestUrl; exports.buildNearMobileUniversalRequestUrl = _chunkNCPQ2YHOjs.buildNearMobileUniversalRequestUrl;
|
package/dist/index.mjs
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import "./chunk-KZFT6V6I.mjs";
|
|
2
2
|
import {
|
|
3
3
|
connector_exports
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-APKMGRUO.mjs";
|
|
5
5
|
import "./chunk-WBQAMGXK.mjs";
|
|
6
6
|
import {
|
|
7
7
|
buildNearMobileAppRequestUrl,
|
|
8
8
|
buildNearMobileUniversalRequestUrl
|
|
9
|
-
} from "./chunk-
|
|
10
|
-
import "./chunk-
|
|
9
|
+
} from "./chunk-GIXEEREC.mjs";
|
|
10
|
+
import "./chunk-OWBUUQRE.mjs";
|
|
11
11
|
import "./chunk-7P6ASYW6.mjs";
|
|
12
12
|
export {
|
|
13
13
|
connector_exports as NearMobileConnector,
|
package/dist/main.d.mts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export { c as NearMobileConnector } from './connector-k1ZUc4Z5.mjs';
|
|
2
2
|
export { buildNearMobileAppRequestUrl, buildNearMobileUniversalRequestUrl } from './utils.mjs';
|
|
3
|
-
export { ConnectorRequestDto, ConnectorRequestRequest, ConnectorRequestResponseRequest, ConnectorSignAndSendTransactionPayloadDto, ConnectorSignAndSendTransactionPayloadRequest, ConnectorSignAndSendTransactionsPayloadDto, ConnectorSignAndSendTransactionsPayloadRequest,
|
|
3
|
+
export { AllowMethodsAllDto, AllowMethodsAllParams, AllowMethodsSelectDto, AllowMethodsSelectParams, ConnectorActionDto, ConnectorActionRequest, ConnectorDelegateActionDto, ConnectorDelegateActionRequest, ConnectorRequestDto, ConnectorRequestRequest, ConnectorRequestResponseRequest, ConnectorSignAndSendTransactionPayloadDto, ConnectorSignAndSendTransactionPayloadRequest, ConnectorSignAndSendTransactionsPayloadDto, ConnectorSignAndSendTransactionsPayloadRequest, ConnectorSignDelegateActionsPayloadDto, ConnectorSignDelegateActionsPayloadRequest, ConnectorSignInAddFunctionCallKeyDto, ConnectorSignInAddFunctionCallKeyParams, ConnectorSignInAndSignMessageDto, ConnectorSignInAndSignMessageParams, ConnectorSignInResponseDto, ConnectorSignInWithKeyPayloadDto, ConnectorSignInWithKeyPayloadRequest, ConnectorSignInWithMessagePayloadDto, ConnectorSignInWithMessagePayloadRequest, ConnectorSignInWithMessageResponseDto, ConnectorSignMessagePayloadDto, ConnectorSignMessagePayloadRequest, ConnectorSignMessageResponseDto, ConnectorTransactionDto, ConnectorTransactionRequest, GasAllowanceLimitedDto, GasAllowanceLimitedParams, GasAllowanceUnlimitedDto, GasAllowanceUnlimitedParams, Polling, PollingOptions } from './types.mjs';
|
|
4
4
|
export { NearMobileQrCode, NearMobileQrCodeOptions } from './strategies/qr-code/qr-code.mjs';
|
|
5
5
|
import 'qr-code-styling';
|
package/dist/main.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export { c as NearMobileConnector } from './connector-o47KNKfA.js';
|
|
2
2
|
export { buildNearMobileAppRequestUrl, buildNearMobileUniversalRequestUrl } from './utils.js';
|
|
3
|
-
export { ConnectorRequestDto, ConnectorRequestRequest, ConnectorRequestResponseRequest, ConnectorSignAndSendTransactionPayloadDto, ConnectorSignAndSendTransactionPayloadRequest, ConnectorSignAndSendTransactionsPayloadDto, ConnectorSignAndSendTransactionsPayloadRequest,
|
|
3
|
+
export { AllowMethodsAllDto, AllowMethodsAllParams, AllowMethodsSelectDto, AllowMethodsSelectParams, ConnectorActionDto, ConnectorActionRequest, ConnectorDelegateActionDto, ConnectorDelegateActionRequest, ConnectorRequestDto, ConnectorRequestRequest, ConnectorRequestResponseRequest, ConnectorSignAndSendTransactionPayloadDto, ConnectorSignAndSendTransactionPayloadRequest, ConnectorSignAndSendTransactionsPayloadDto, ConnectorSignAndSendTransactionsPayloadRequest, ConnectorSignDelegateActionsPayloadDto, ConnectorSignDelegateActionsPayloadRequest, ConnectorSignInAddFunctionCallKeyDto, ConnectorSignInAddFunctionCallKeyParams, ConnectorSignInAndSignMessageDto, ConnectorSignInAndSignMessageParams, ConnectorSignInResponseDto, ConnectorSignInWithKeyPayloadDto, ConnectorSignInWithKeyPayloadRequest, ConnectorSignInWithMessagePayloadDto, ConnectorSignInWithMessagePayloadRequest, ConnectorSignInWithMessageResponseDto, ConnectorSignMessagePayloadDto, ConnectorSignMessagePayloadRequest, ConnectorSignMessageResponseDto, ConnectorTransactionDto, ConnectorTransactionRequest, GasAllowanceLimitedDto, GasAllowanceLimitedParams, GasAllowanceUnlimitedDto, GasAllowanceUnlimitedParams, Polling, PollingOptions } from './types.js';
|
|
4
4
|
export { NearMobileQrCode, NearMobileQrCodeOptions } from './strategies/qr-code/qr-code.js';
|
|
5
5
|
import 'qr-code-styling';
|
package/dist/main.js
CHANGED
|
@@ -1,22 +1,22 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});require('./chunk-6KQS7CTR.js');
|
|
2
2
|
|
|
3
3
|
|
|
4
|
-
var
|
|
4
|
+
var _chunkZZJKEHX6js = require('./chunk-ZZJKEHX6.js');
|
|
5
5
|
require('./chunk-6F4PWJZI.js');
|
|
6
6
|
require('./chunk-54IKIQKG.js');
|
|
7
7
|
|
|
8
8
|
|
|
9
|
-
var
|
|
9
|
+
var _chunkJLBRCZBFjs = require('./chunk-JLBRCZBF.js');
|
|
10
10
|
|
|
11
11
|
|
|
12
12
|
|
|
13
|
-
var
|
|
14
|
-
require('./chunk-
|
|
15
|
-
require('./chunk-
|
|
13
|
+
var _chunkNCPQ2YHOjs = require('./chunk-NCPQ2YHO.js');
|
|
14
|
+
require('./chunk-7VPD5BML.js');
|
|
15
|
+
require('./chunk-HVMVKTGG.js');
|
|
16
16
|
require('./chunk-MLKGABMK.js');
|
|
17
17
|
|
|
18
18
|
|
|
19
19
|
|
|
20
20
|
|
|
21
21
|
|
|
22
|
-
exports.NearMobileConnector =
|
|
22
|
+
exports.NearMobileConnector = _chunkZZJKEHX6js.connector_exports; exports.NearMobileQrCode = _chunkJLBRCZBFjs.NearMobileQrCode; exports.buildNearMobileAppRequestUrl = _chunkNCPQ2YHOjs.buildNearMobileAppRequestUrl; exports.buildNearMobileUniversalRequestUrl = _chunkNCPQ2YHOjs.buildNearMobileUniversalRequestUrl;
|
package/dist/main.mjs
CHANGED
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
import "./chunk-KZFT6V6I.mjs";
|
|
2
2
|
import {
|
|
3
3
|
connector_exports
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-APKMGRUO.mjs";
|
|
5
5
|
import "./chunk-WBQAMGXK.mjs";
|
|
6
6
|
import "./chunk-CBQC7ETP.mjs";
|
|
7
7
|
import {
|
|
8
8
|
NearMobileQrCode
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-B2YNUFH6.mjs";
|
|
10
10
|
import {
|
|
11
11
|
buildNearMobileAppRequestUrl,
|
|
12
12
|
buildNearMobileUniversalRequestUrl
|
|
13
|
-
} from "./chunk-
|
|
14
|
-
import "./chunk-
|
|
15
|
-
import "./chunk-
|
|
13
|
+
} from "./chunk-GIXEEREC.mjs";
|
|
14
|
+
import "./chunk-OWBUUQRE.mjs";
|
|
15
|
+
import "./chunk-L2EA5E7P.mjs";
|
|
16
16
|
import "./chunk-7P6ASYW6.mjs";
|
|
17
17
|
export {
|
|
18
18
|
connector_exports as NearMobileConnector,
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});require('../../chunk-54IKIQKG.js');
|
|
2
2
|
|
|
3
3
|
|
|
4
|
-
var
|
|
5
|
-
require('../../chunk-
|
|
6
|
-
require('../../chunk-
|
|
7
|
-
require('../../chunk-
|
|
4
|
+
var _chunkJLBRCZBFjs = require('../../chunk-JLBRCZBF.js');
|
|
5
|
+
require('../../chunk-NCPQ2YHO.js');
|
|
6
|
+
require('../../chunk-7VPD5BML.js');
|
|
7
|
+
require('../../chunk-HVMVKTGG.js');
|
|
8
8
|
require('../../chunk-MLKGABMK.js');
|
|
9
9
|
|
|
10
10
|
|
|
11
|
-
exports.NearMobileQrCode =
|
|
11
|
+
exports.NearMobileQrCode = _chunkJLBRCZBFjs.NearMobileQrCode;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import "../../chunk-CBQC7ETP.mjs";
|
|
2
2
|
import {
|
|
3
3
|
NearMobileQrCode
|
|
4
|
-
} from "../../chunk-
|
|
5
|
-
import "../../chunk-
|
|
6
|
-
import "../../chunk-
|
|
7
|
-
import "../../chunk-
|
|
4
|
+
} from "../../chunk-B2YNUFH6.mjs";
|
|
5
|
+
import "../../chunk-GIXEEREC.mjs";
|
|
6
|
+
import "../../chunk-OWBUUQRE.mjs";
|
|
7
|
+
import "../../chunk-L2EA5E7P.mjs";
|
|
8
8
|
import "../../chunk-7P6ASYW6.mjs";
|
|
9
9
|
export {
|
|
10
10
|
NearMobileQrCode
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var _chunkHVMVKTGGjs = require('../../chunk-HVMVKTGG.js');
|
|
4
4
|
require('../../chunk-MLKGABMK.js');
|
|
5
5
|
|
|
6
6
|
|
|
7
|
-
exports.qrCodeConfig =
|
|
7
|
+
exports.qrCodeConfig = _chunkHVMVKTGGjs.qrCodeConfig;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
2
|
|
|
3
|
-
var
|
|
4
|
-
require('../../chunk-
|
|
5
|
-
require('../../chunk-
|
|
6
|
-
require('../../chunk-
|
|
3
|
+
var _chunkJLBRCZBFjs = require('../../chunk-JLBRCZBF.js');
|
|
4
|
+
require('../../chunk-NCPQ2YHO.js');
|
|
5
|
+
require('../../chunk-7VPD5BML.js');
|
|
6
|
+
require('../../chunk-HVMVKTGG.js');
|
|
7
7
|
require('../../chunk-MLKGABMK.js');
|
|
8
8
|
|
|
9
9
|
|
|
10
|
-
exports.NearMobileQrCode =
|
|
10
|
+
exports.NearMobileQrCode = _chunkJLBRCZBFjs.NearMobileQrCode;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import {
|
|
2
2
|
NearMobileQrCode
|
|
3
|
-
} from "../../chunk-
|
|
4
|
-
import "../../chunk-
|
|
5
|
-
import "../../chunk-
|
|
6
|
-
import "../../chunk-
|
|
3
|
+
} from "../../chunk-B2YNUFH6.mjs";
|
|
4
|
+
import "../../chunk-GIXEEREC.mjs";
|
|
5
|
+
import "../../chunk-OWBUUQRE.mjs";
|
|
6
|
+
import "../../chunk-L2EA5E7P.mjs";
|
|
7
7
|
import "../../chunk-7P6ASYW6.mjs";
|
|
8
8
|
export {
|
|
9
9
|
NearMobileQrCode
|
package/dist/types.d.mts
CHANGED
|
@@ -1,3 +1,21 @@
|
|
|
1
|
+
type AllowMethodsAllDto = {
|
|
2
|
+
anyMethod: boolean;
|
|
3
|
+
};
|
|
4
|
+
|
|
5
|
+
type AllowMethodsAllParams = {
|
|
6
|
+
anyMethod: boolean;
|
|
7
|
+
};
|
|
8
|
+
|
|
9
|
+
type AllowMethodsSelectDto = {
|
|
10
|
+
anyMethod: boolean;
|
|
11
|
+
methodNames: Array<string>;
|
|
12
|
+
};
|
|
13
|
+
|
|
14
|
+
type AllowMethodsSelectParams = {
|
|
15
|
+
anyMethod: boolean;
|
|
16
|
+
methodNames: Array<string>;
|
|
17
|
+
};
|
|
18
|
+
|
|
1
19
|
type ConnectorActionDto = {
|
|
2
20
|
type: string;
|
|
3
21
|
params?: Record<string, any>;
|
|
@@ -8,8 +26,18 @@ type ConnectorActionRequest = {
|
|
|
8
26
|
params?: Array<Record<string, any>>;
|
|
9
27
|
};
|
|
10
28
|
|
|
29
|
+
type ConnectorDelegateActionDto = {
|
|
30
|
+
receiverId: string;
|
|
31
|
+
actions: Array<ConnectorActionDto>;
|
|
32
|
+
};
|
|
33
|
+
|
|
34
|
+
type ConnectorDelegateActionRequest = {
|
|
35
|
+
receiverId: string;
|
|
36
|
+
actions: Array<ConnectorActionRequest>;
|
|
37
|
+
};
|
|
38
|
+
|
|
11
39
|
type ConnectorRequestDto = {
|
|
12
|
-
method: 'signIn' | 'signMessage' | 'signAndSendTransaction' | 'signAndSendTransactions';
|
|
40
|
+
method: 'signIn' | 'signMessage' | 'signAndSendTransaction' | 'signAndSendTransactions' | 'signDelegateActions';
|
|
13
41
|
status: 'pending' | 'approved' | 'rejected';
|
|
14
42
|
network: 'mainnet' | 'testnet';
|
|
15
43
|
id: string;
|
|
@@ -22,7 +50,7 @@ type ConnectorRequestDto = {
|
|
|
22
50
|
};
|
|
23
51
|
|
|
24
52
|
type ConnectorRequestRequest = {
|
|
25
|
-
method: 'signIn' | 'signMessage' | 'signAndSendTransaction' | 'signAndSendTransactions';
|
|
53
|
+
method: 'signIn' | 'signMessage' | 'signAndSendTransaction' | 'signAndSendTransactions' | 'signDelegateActions';
|
|
26
54
|
network: 'mainnet' | 'testnet';
|
|
27
55
|
origin: string;
|
|
28
56
|
payload?: Record<string, any>;
|
|
@@ -34,9 +62,9 @@ type ConnectorRequestResponseRequest = {
|
|
|
34
62
|
};
|
|
35
63
|
|
|
36
64
|
type ConnectorSignAndSendTransactionPayloadDto = {
|
|
37
|
-
actions: Array<ConnectorActionDto>;
|
|
38
65
|
signerId?: string;
|
|
39
66
|
receiverId: string;
|
|
67
|
+
actions: Array<ConnectorActionDto>;
|
|
40
68
|
};
|
|
41
69
|
|
|
42
70
|
type ConnectorSignAndSendTransactionPayloadRequest = {
|
|
@@ -51,13 +79,13 @@ type ConnectorTransactionDto = {
|
|
|
51
79
|
};
|
|
52
80
|
|
|
53
81
|
type ConnectorSignAndSendTransactionsPayloadDto = {
|
|
54
|
-
transactions: Array<ConnectorTransactionDto>;
|
|
55
82
|
signerId?: string;
|
|
83
|
+
transactions: Array<ConnectorTransactionDto>;
|
|
56
84
|
};
|
|
57
85
|
|
|
58
86
|
type ConnectorTransactionRequest = {
|
|
59
87
|
receiverId: string;
|
|
60
|
-
actions:
|
|
88
|
+
actions: ConnectorActionRequest;
|
|
61
89
|
};
|
|
62
90
|
|
|
63
91
|
type ConnectorSignAndSendTransactionsPayloadRequest = {
|
|
@@ -65,32 +93,79 @@ type ConnectorSignAndSendTransactionsPayloadRequest = {
|
|
|
65
93
|
transactions: Array<ConnectorTransactionRequest>;
|
|
66
94
|
};
|
|
67
95
|
|
|
68
|
-
type
|
|
69
|
-
|
|
96
|
+
type ConnectorSignDelegateActionsPayloadDto = {
|
|
97
|
+
signerId?: string;
|
|
98
|
+
delegateActions: Array<Array<ConnectorDelegateActionDto>>;
|
|
70
99
|
};
|
|
71
100
|
|
|
72
|
-
type
|
|
73
|
-
|
|
74
|
-
|
|
101
|
+
type ConnectorSignDelegateActionsPayloadRequest = {
|
|
102
|
+
signerId?: string;
|
|
103
|
+
delegateActions: Array<ConnectorDelegateActionRequest>;
|
|
75
104
|
};
|
|
76
105
|
|
|
77
|
-
type
|
|
78
|
-
|
|
106
|
+
type GasAllowanceLimitedDto = {
|
|
107
|
+
kind: string;
|
|
108
|
+
amount: string;
|
|
109
|
+
};
|
|
110
|
+
|
|
111
|
+
type GasAllowanceUnlimitedDto = {
|
|
112
|
+
kind: string;
|
|
113
|
+
};
|
|
114
|
+
|
|
115
|
+
type ConnectorSignInAddFunctionCallKeyDto = {
|
|
116
|
+
contractId: string;
|
|
79
117
|
publicKey: string;
|
|
118
|
+
allowMethods: (AllowMethodsAllDto | AllowMethodsSelectDto);
|
|
119
|
+
gasAllowance?: (GasAllowanceUnlimitedDto | GasAllowanceLimitedDto);
|
|
80
120
|
};
|
|
81
121
|
|
|
82
|
-
type
|
|
83
|
-
|
|
122
|
+
type GasAllowanceLimitedParams = {
|
|
123
|
+
kind: string;
|
|
124
|
+
amount: string;
|
|
125
|
+
};
|
|
126
|
+
|
|
127
|
+
type GasAllowanceUnlimitedParams = {
|
|
128
|
+
kind: string;
|
|
129
|
+
};
|
|
130
|
+
|
|
131
|
+
type ConnectorSignInAddFunctionCallKeyParams = {
|
|
132
|
+
contractId: string;
|
|
133
|
+
publicKey: string;
|
|
134
|
+
allowMethods: (AllowMethodsAllParams | AllowMethodsSelectParams);
|
|
135
|
+
gasAllowance?: (GasAllowanceUnlimitedParams | GasAllowanceLimitedParams);
|
|
136
|
+
};
|
|
137
|
+
|
|
138
|
+
type ConnectorSignInAndSignMessageDto = {
|
|
84
139
|
message: string;
|
|
85
140
|
recipient: string;
|
|
86
|
-
|
|
141
|
+
nonce: Array<number>;
|
|
87
142
|
};
|
|
88
143
|
|
|
89
|
-
type
|
|
144
|
+
type ConnectorSignInAndSignMessageParams = {
|
|
90
145
|
message: string;
|
|
91
146
|
recipient: string;
|
|
92
|
-
nonce: Array<
|
|
93
|
-
|
|
147
|
+
nonce: Array<number>;
|
|
148
|
+
};
|
|
149
|
+
|
|
150
|
+
type ConnectorSignInResponseDto = {
|
|
151
|
+
accountId: string;
|
|
152
|
+
publicKey: string;
|
|
153
|
+
};
|
|
154
|
+
|
|
155
|
+
type ConnectorSignInWithKeyPayloadDto = {
|
|
156
|
+
addFunctionCallKey: ConnectorSignInAddFunctionCallKeyDto;
|
|
157
|
+
};
|
|
158
|
+
|
|
159
|
+
type ConnectorSignInWithKeyPayloadRequest = {
|
|
160
|
+
addFunctionCallKey: ConnectorSignInAddFunctionCallKeyParams;
|
|
161
|
+
};
|
|
162
|
+
|
|
163
|
+
type ConnectorSignInWithMessagePayloadDto = {
|
|
164
|
+
messageParams: ConnectorSignInAndSignMessageDto;
|
|
165
|
+
};
|
|
166
|
+
|
|
167
|
+
type ConnectorSignInWithMessagePayloadRequest = {
|
|
168
|
+
messageParams: ConnectorSignInAndSignMessageParams;
|
|
94
169
|
};
|
|
95
170
|
|
|
96
171
|
type ConnectorSignMessageResponseDto = {
|
|
@@ -99,6 +174,26 @@ type ConnectorSignMessageResponseDto = {
|
|
|
99
174
|
signature: string;
|
|
100
175
|
};
|
|
101
176
|
|
|
177
|
+
type ConnectorSignInWithMessageResponseDto = {
|
|
178
|
+
accountId: string;
|
|
179
|
+
publicKey: string;
|
|
180
|
+
signedMessage: ConnectorSignMessageResponseDto;
|
|
181
|
+
};
|
|
182
|
+
|
|
183
|
+
type ConnectorSignMessagePayloadDto = {
|
|
184
|
+
message: string;
|
|
185
|
+
recipient: string;
|
|
186
|
+
nonce: Array<number>;
|
|
187
|
+
signerId?: string;
|
|
188
|
+
};
|
|
189
|
+
|
|
190
|
+
type ConnectorSignMessagePayloadRequest = {
|
|
191
|
+
message: string;
|
|
192
|
+
recipient: string;
|
|
193
|
+
nonce: Array<number>;
|
|
194
|
+
signerId?: string;
|
|
195
|
+
};
|
|
196
|
+
|
|
102
197
|
type Polling<R> = Promise<R> & {
|
|
103
198
|
abort(): void;
|
|
104
199
|
};
|
|
@@ -108,4 +203,4 @@ type PollingOptions = {
|
|
|
108
203
|
timeout?: number;
|
|
109
204
|
};
|
|
110
205
|
|
|
111
|
-
export type { ConnectorRequestDto, ConnectorRequestRequest, ConnectorRequestResponseRequest, ConnectorSignAndSendTransactionPayloadDto, ConnectorSignAndSendTransactionPayloadRequest, ConnectorSignAndSendTransactionsPayloadDto, ConnectorSignAndSendTransactionsPayloadRequest,
|
|
206
|
+
export type { AllowMethodsAllDto, AllowMethodsAllParams, AllowMethodsSelectDto, AllowMethodsSelectParams, ConnectorActionDto, ConnectorActionRequest, ConnectorDelegateActionDto, ConnectorDelegateActionRequest, ConnectorRequestDto, ConnectorRequestRequest, ConnectorRequestResponseRequest, ConnectorSignAndSendTransactionPayloadDto, ConnectorSignAndSendTransactionPayloadRequest, ConnectorSignAndSendTransactionsPayloadDto, ConnectorSignAndSendTransactionsPayloadRequest, ConnectorSignDelegateActionsPayloadDto, ConnectorSignDelegateActionsPayloadRequest, ConnectorSignInAddFunctionCallKeyDto, ConnectorSignInAddFunctionCallKeyParams, ConnectorSignInAndSignMessageDto, ConnectorSignInAndSignMessageParams, ConnectorSignInResponseDto, ConnectorSignInWithKeyPayloadDto, ConnectorSignInWithKeyPayloadRequest, ConnectorSignInWithMessagePayloadDto, ConnectorSignInWithMessagePayloadRequest, ConnectorSignInWithMessageResponseDto, ConnectorSignMessagePayloadDto, ConnectorSignMessagePayloadRequest, ConnectorSignMessageResponseDto, ConnectorTransactionDto, ConnectorTransactionRequest, GasAllowanceLimitedDto, GasAllowanceLimitedParams, GasAllowanceUnlimitedDto, GasAllowanceUnlimitedParams, Polling, PollingOptions };
|
package/dist/types.d.ts
CHANGED
|
@@ -1,3 +1,21 @@
|
|
|
1
|
+
type AllowMethodsAllDto = {
|
|
2
|
+
anyMethod: boolean;
|
|
3
|
+
};
|
|
4
|
+
|
|
5
|
+
type AllowMethodsAllParams = {
|
|
6
|
+
anyMethod: boolean;
|
|
7
|
+
};
|
|
8
|
+
|
|
9
|
+
type AllowMethodsSelectDto = {
|
|
10
|
+
anyMethod: boolean;
|
|
11
|
+
methodNames: Array<string>;
|
|
12
|
+
};
|
|
13
|
+
|
|
14
|
+
type AllowMethodsSelectParams = {
|
|
15
|
+
anyMethod: boolean;
|
|
16
|
+
methodNames: Array<string>;
|
|
17
|
+
};
|
|
18
|
+
|
|
1
19
|
type ConnectorActionDto = {
|
|
2
20
|
type: string;
|
|
3
21
|
params?: Record<string, any>;
|
|
@@ -8,8 +26,18 @@ type ConnectorActionRequest = {
|
|
|
8
26
|
params?: Array<Record<string, any>>;
|
|
9
27
|
};
|
|
10
28
|
|
|
29
|
+
type ConnectorDelegateActionDto = {
|
|
30
|
+
receiverId: string;
|
|
31
|
+
actions: Array<ConnectorActionDto>;
|
|
32
|
+
};
|
|
33
|
+
|
|
34
|
+
type ConnectorDelegateActionRequest = {
|
|
35
|
+
receiverId: string;
|
|
36
|
+
actions: Array<ConnectorActionRequest>;
|
|
37
|
+
};
|
|
38
|
+
|
|
11
39
|
type ConnectorRequestDto = {
|
|
12
|
-
method: 'signIn' | 'signMessage' | 'signAndSendTransaction' | 'signAndSendTransactions';
|
|
40
|
+
method: 'signIn' | 'signMessage' | 'signAndSendTransaction' | 'signAndSendTransactions' | 'signDelegateActions';
|
|
13
41
|
status: 'pending' | 'approved' | 'rejected';
|
|
14
42
|
network: 'mainnet' | 'testnet';
|
|
15
43
|
id: string;
|
|
@@ -22,7 +50,7 @@ type ConnectorRequestDto = {
|
|
|
22
50
|
};
|
|
23
51
|
|
|
24
52
|
type ConnectorRequestRequest = {
|
|
25
|
-
method: 'signIn' | 'signMessage' | 'signAndSendTransaction' | 'signAndSendTransactions';
|
|
53
|
+
method: 'signIn' | 'signMessage' | 'signAndSendTransaction' | 'signAndSendTransactions' | 'signDelegateActions';
|
|
26
54
|
network: 'mainnet' | 'testnet';
|
|
27
55
|
origin: string;
|
|
28
56
|
payload?: Record<string, any>;
|
|
@@ -34,9 +62,9 @@ type ConnectorRequestResponseRequest = {
|
|
|
34
62
|
};
|
|
35
63
|
|
|
36
64
|
type ConnectorSignAndSendTransactionPayloadDto = {
|
|
37
|
-
actions: Array<ConnectorActionDto>;
|
|
38
65
|
signerId?: string;
|
|
39
66
|
receiverId: string;
|
|
67
|
+
actions: Array<ConnectorActionDto>;
|
|
40
68
|
};
|
|
41
69
|
|
|
42
70
|
type ConnectorSignAndSendTransactionPayloadRequest = {
|
|
@@ -51,13 +79,13 @@ type ConnectorTransactionDto = {
|
|
|
51
79
|
};
|
|
52
80
|
|
|
53
81
|
type ConnectorSignAndSendTransactionsPayloadDto = {
|
|
54
|
-
transactions: Array<ConnectorTransactionDto>;
|
|
55
82
|
signerId?: string;
|
|
83
|
+
transactions: Array<ConnectorTransactionDto>;
|
|
56
84
|
};
|
|
57
85
|
|
|
58
86
|
type ConnectorTransactionRequest = {
|
|
59
87
|
receiverId: string;
|
|
60
|
-
actions:
|
|
88
|
+
actions: ConnectorActionRequest;
|
|
61
89
|
};
|
|
62
90
|
|
|
63
91
|
type ConnectorSignAndSendTransactionsPayloadRequest = {
|
|
@@ -65,32 +93,79 @@ type ConnectorSignAndSendTransactionsPayloadRequest = {
|
|
|
65
93
|
transactions: Array<ConnectorTransactionRequest>;
|
|
66
94
|
};
|
|
67
95
|
|
|
68
|
-
type
|
|
69
|
-
|
|
96
|
+
type ConnectorSignDelegateActionsPayloadDto = {
|
|
97
|
+
signerId?: string;
|
|
98
|
+
delegateActions: Array<Array<ConnectorDelegateActionDto>>;
|
|
70
99
|
};
|
|
71
100
|
|
|
72
|
-
type
|
|
73
|
-
|
|
74
|
-
|
|
101
|
+
type ConnectorSignDelegateActionsPayloadRequest = {
|
|
102
|
+
signerId?: string;
|
|
103
|
+
delegateActions: Array<ConnectorDelegateActionRequest>;
|
|
75
104
|
};
|
|
76
105
|
|
|
77
|
-
type
|
|
78
|
-
|
|
106
|
+
type GasAllowanceLimitedDto = {
|
|
107
|
+
kind: string;
|
|
108
|
+
amount: string;
|
|
109
|
+
};
|
|
110
|
+
|
|
111
|
+
type GasAllowanceUnlimitedDto = {
|
|
112
|
+
kind: string;
|
|
113
|
+
};
|
|
114
|
+
|
|
115
|
+
type ConnectorSignInAddFunctionCallKeyDto = {
|
|
116
|
+
contractId: string;
|
|
79
117
|
publicKey: string;
|
|
118
|
+
allowMethods: (AllowMethodsAllDto | AllowMethodsSelectDto);
|
|
119
|
+
gasAllowance?: (GasAllowanceUnlimitedDto | GasAllowanceLimitedDto);
|
|
80
120
|
};
|
|
81
121
|
|
|
82
|
-
type
|
|
83
|
-
|
|
122
|
+
type GasAllowanceLimitedParams = {
|
|
123
|
+
kind: string;
|
|
124
|
+
amount: string;
|
|
125
|
+
};
|
|
126
|
+
|
|
127
|
+
type GasAllowanceUnlimitedParams = {
|
|
128
|
+
kind: string;
|
|
129
|
+
};
|
|
130
|
+
|
|
131
|
+
type ConnectorSignInAddFunctionCallKeyParams = {
|
|
132
|
+
contractId: string;
|
|
133
|
+
publicKey: string;
|
|
134
|
+
allowMethods: (AllowMethodsAllParams | AllowMethodsSelectParams);
|
|
135
|
+
gasAllowance?: (GasAllowanceUnlimitedParams | GasAllowanceLimitedParams);
|
|
136
|
+
};
|
|
137
|
+
|
|
138
|
+
type ConnectorSignInAndSignMessageDto = {
|
|
84
139
|
message: string;
|
|
85
140
|
recipient: string;
|
|
86
|
-
|
|
141
|
+
nonce: Array<number>;
|
|
87
142
|
};
|
|
88
143
|
|
|
89
|
-
type
|
|
144
|
+
type ConnectorSignInAndSignMessageParams = {
|
|
90
145
|
message: string;
|
|
91
146
|
recipient: string;
|
|
92
|
-
nonce: Array<
|
|
93
|
-
|
|
147
|
+
nonce: Array<number>;
|
|
148
|
+
};
|
|
149
|
+
|
|
150
|
+
type ConnectorSignInResponseDto = {
|
|
151
|
+
accountId: string;
|
|
152
|
+
publicKey: string;
|
|
153
|
+
};
|
|
154
|
+
|
|
155
|
+
type ConnectorSignInWithKeyPayloadDto = {
|
|
156
|
+
addFunctionCallKey: ConnectorSignInAddFunctionCallKeyDto;
|
|
157
|
+
};
|
|
158
|
+
|
|
159
|
+
type ConnectorSignInWithKeyPayloadRequest = {
|
|
160
|
+
addFunctionCallKey: ConnectorSignInAddFunctionCallKeyParams;
|
|
161
|
+
};
|
|
162
|
+
|
|
163
|
+
type ConnectorSignInWithMessagePayloadDto = {
|
|
164
|
+
messageParams: ConnectorSignInAndSignMessageDto;
|
|
165
|
+
};
|
|
166
|
+
|
|
167
|
+
type ConnectorSignInWithMessagePayloadRequest = {
|
|
168
|
+
messageParams: ConnectorSignInAndSignMessageParams;
|
|
94
169
|
};
|
|
95
170
|
|
|
96
171
|
type ConnectorSignMessageResponseDto = {
|
|
@@ -99,6 +174,26 @@ type ConnectorSignMessageResponseDto = {
|
|
|
99
174
|
signature: string;
|
|
100
175
|
};
|
|
101
176
|
|
|
177
|
+
type ConnectorSignInWithMessageResponseDto = {
|
|
178
|
+
accountId: string;
|
|
179
|
+
publicKey: string;
|
|
180
|
+
signedMessage: ConnectorSignMessageResponseDto;
|
|
181
|
+
};
|
|
182
|
+
|
|
183
|
+
type ConnectorSignMessagePayloadDto = {
|
|
184
|
+
message: string;
|
|
185
|
+
recipient: string;
|
|
186
|
+
nonce: Array<number>;
|
|
187
|
+
signerId?: string;
|
|
188
|
+
};
|
|
189
|
+
|
|
190
|
+
type ConnectorSignMessagePayloadRequest = {
|
|
191
|
+
message: string;
|
|
192
|
+
recipient: string;
|
|
193
|
+
nonce: Array<number>;
|
|
194
|
+
signerId?: string;
|
|
195
|
+
};
|
|
196
|
+
|
|
102
197
|
type Polling<R> = Promise<R> & {
|
|
103
198
|
abort(): void;
|
|
104
199
|
};
|
|
@@ -108,4 +203,4 @@ type PollingOptions = {
|
|
|
108
203
|
timeout?: number;
|
|
109
204
|
};
|
|
110
205
|
|
|
111
|
-
export type { ConnectorRequestDto, ConnectorRequestRequest, ConnectorRequestResponseRequest, ConnectorSignAndSendTransactionPayloadDto, ConnectorSignAndSendTransactionPayloadRequest, ConnectorSignAndSendTransactionsPayloadDto, ConnectorSignAndSendTransactionsPayloadRequest,
|
|
206
|
+
export type { AllowMethodsAllDto, AllowMethodsAllParams, AllowMethodsSelectDto, AllowMethodsSelectParams, ConnectorActionDto, ConnectorActionRequest, ConnectorDelegateActionDto, ConnectorDelegateActionRequest, ConnectorRequestDto, ConnectorRequestRequest, ConnectorRequestResponseRequest, ConnectorSignAndSendTransactionPayloadDto, ConnectorSignAndSendTransactionPayloadRequest, ConnectorSignAndSendTransactionsPayloadDto, ConnectorSignAndSendTransactionsPayloadRequest, ConnectorSignDelegateActionsPayloadDto, ConnectorSignDelegateActionsPayloadRequest, ConnectorSignInAddFunctionCallKeyDto, ConnectorSignInAddFunctionCallKeyParams, ConnectorSignInAndSignMessageDto, ConnectorSignInAndSignMessageParams, ConnectorSignInResponseDto, ConnectorSignInWithKeyPayloadDto, ConnectorSignInWithKeyPayloadRequest, ConnectorSignInWithMessagePayloadDto, ConnectorSignInWithMessagePayloadRequest, ConnectorSignInWithMessageResponseDto, ConnectorSignMessagePayloadDto, ConnectorSignMessagePayloadRequest, ConnectorSignMessageResponseDto, ConnectorTransactionDto, ConnectorTransactionRequest, GasAllowanceLimitedDto, GasAllowanceLimitedParams, GasAllowanceUnlimitedDto, GasAllowanceUnlimitedParams, Polling, PollingOptions };
|
package/dist/utils.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
2
|
|
|
3
3
|
|
|
4
|
-
var
|
|
5
|
-
require('./chunk-
|
|
4
|
+
var _chunkNCPQ2YHOjs = require('./chunk-NCPQ2YHO.js');
|
|
5
|
+
require('./chunk-7VPD5BML.js');
|
|
6
6
|
require('./chunk-MLKGABMK.js');
|
|
7
7
|
|
|
8
8
|
|
|
9
9
|
|
|
10
|
-
exports.buildNearMobileAppRequestUrl =
|
|
10
|
+
exports.buildNearMobileAppRequestUrl = _chunkNCPQ2YHOjs.buildNearMobileAppRequestUrl; exports.buildNearMobileUniversalRequestUrl = _chunkNCPQ2YHOjs.buildNearMobileUniversalRequestUrl;
|
package/dist/utils.mjs
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import {
|
|
2
2
|
buildNearMobileAppRequestUrl,
|
|
3
3
|
buildNearMobileUniversalRequestUrl
|
|
4
|
-
} from "./chunk-
|
|
5
|
-
import "./chunk-
|
|
4
|
+
} from "./chunk-GIXEEREC.mjs";
|
|
5
|
+
import "./chunk-OWBUUQRE.mjs";
|
|
6
6
|
import "./chunk-7P6ASYW6.mjs";
|
|
7
7
|
export {
|
|
8
8
|
buildNearMobileAppRequestUrl,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@near-mobile/connector",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.3",
|
|
4
4
|
"description": "Public client for the Near Mobile Connector: create requests, poll for responses, build deep-link URLs, and generate QR codes for wallet connections.",
|
|
5
5
|
"author": "Peersyst",
|
|
6
6
|
"license": "MIT",
|
|
@@ -30,16 +30,8 @@
|
|
|
30
30
|
"module": "./dist/main.mjs",
|
|
31
31
|
"types": "./dist/main.d.ts",
|
|
32
32
|
"exports": {
|
|
33
|
-
".":
|
|
34
|
-
|
|
35
|
-
"import": "./dist/index.mjs",
|
|
36
|
-
"require": "./dist/index.js"
|
|
37
|
-
},
|
|
38
|
-
"./strategies/qr-code": {
|
|
39
|
-
"types": "./dist/strategies/qr-code/index.d.ts",
|
|
40
|
-
"import": "./dist/strategies/qr-code/index.mjs",
|
|
41
|
-
"require": "./dist/strategies/qr-code/index.js"
|
|
42
|
-
}
|
|
33
|
+
".": "./src/index.ts",
|
|
34
|
+
"./strategies/qr-code": "./src/strategies/qr-code/index.ts"
|
|
43
35
|
},
|
|
44
36
|
"typesVersions": {
|
|
45
37
|
"*": {
|
|
@@ -60,19 +52,22 @@
|
|
|
60
52
|
"check-types": "npx tsc --noEmit",
|
|
61
53
|
"generate-api": "openapi -i ../../../apps/connector/openapi-spec.json -o src/api/openapi --exportSchemas=true --exportModels=true --useUnionTypes --postfixServices=Api"
|
|
62
54
|
},
|
|
63
|
-
"
|
|
64
|
-
"qr-code-styling": "
|
|
55
|
+
"peerDependencies": {
|
|
56
|
+
"qr-code-styling": "1.9.2"
|
|
65
57
|
},
|
|
66
58
|
"devDependencies": {
|
|
59
|
+
"@noble/ciphers": "0.2.0",
|
|
60
|
+
"@noble/hashes": "1.7.1",
|
|
67
61
|
"@shared/connector": "workspace:*",
|
|
68
62
|
"@shared/eslint": "workspace:*",
|
|
69
63
|
"@shared/tsconfig": "workspace:*",
|
|
70
64
|
"@shared/tsup": "workspace:*",
|
|
71
65
|
"@shared/utils": "workspace:*",
|
|
72
66
|
"@types/node": "latest",
|
|
73
|
-
"eslint": "
|
|
74
|
-
"openapi-typescript": "
|
|
75
|
-
"openapi-typescript-codegen": "
|
|
76
|
-
"typescript": "latest"
|
|
67
|
+
"eslint": "8.57.0",
|
|
68
|
+
"openapi-typescript": "7.3.0",
|
|
69
|
+
"openapi-typescript-codegen": "0.29.0",
|
|
70
|
+
"typescript": "latest",
|
|
71
|
+
"validator": "13.15.26"
|
|
77
72
|
}
|
|
78
73
|
}
|