@ckb-ccc/rei 1.0.13 → 1.0.15
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/CHANGELOG.md +8 -6
- package/dist/signersFactory.d.ts +3 -2
- package/dist/signersFactory.d.ts.map +1 -1
- package/dist/signersFactory.js +5 -4
- package/dist.commonjs/advanced.js +17 -7
- package/dist.commonjs/index.js +17 -7
- package/dist.commonjs/signersFactory.d.ts +3 -2
- package/dist.commonjs/signersFactory.d.ts.map +1 -1
- package/dist.commonjs/signersFactory.js +5 -4
- package/package.json +2 -2
- package/src/signersFactory.ts +6 -6
package/CHANGELOG.md
CHANGED
|
@@ -1,20 +1,22 @@
|
|
|
1
1
|
# @ckb-ccc/rei
|
|
2
2
|
|
|
3
|
-
## 1.0.
|
|
3
|
+
## 1.0.15
|
|
4
4
|
|
|
5
5
|
### Patch Changes
|
|
6
6
|
|
|
7
|
-
-
|
|
8
|
-
|
|
7
|
+
- [`e19bd16`](https://github.com/ckb-devrel/ccc/commit/e19bd16c1375bb66fa5b66f37a07792e594176e4) Thanks [@Hanssen0](https://github.com/Hanssen0)! - fix: update window.rei.ckb
|
|
8
|
+
|
|
9
|
+
- Updated dependencies [[`e19bd16`](https://github.com/ckb-devrel/ccc/commit/e19bd16c1375bb66fa5b66f37a07792e594176e4), [`e19bd16`](https://github.com/ckb-devrel/ccc/commit/e19bd16c1375bb66fa5b66f37a07792e594176e4), [`e19bd16`](https://github.com/ckb-devrel/ccc/commit/e19bd16c1375bb66fa5b66f37a07792e594176e4), [`e19bd16`](https://github.com/ckb-devrel/ccc/commit/e19bd16c1375bb66fa5b66f37a07792e594176e4), [`e19bd16`](https://github.com/ckb-devrel/ccc/commit/e19bd16c1375bb66fa5b66f37a07792e594176e4), [`e19bd16`](https://github.com/ckb-devrel/ccc/commit/e19bd16c1375bb66fa5b66f37a07792e594176e4), [`e19bd16`](https://github.com/ckb-devrel/ccc/commit/e19bd16c1375bb66fa5b66f37a07792e594176e4), [`e19bd16`](https://github.com/ckb-devrel/ccc/commit/e19bd16c1375bb66fa5b66f37a07792e594176e4), [`e19bd16`](https://github.com/ckb-devrel/ccc/commit/e19bd16c1375bb66fa5b66f37a07792e594176e4), [`e19bd16`](https://github.com/ckb-devrel/ccc/commit/e19bd16c1375bb66fa5b66f37a07792e594176e4), [`e19bd16`](https://github.com/ckb-devrel/ccc/commit/e19bd16c1375bb66fa5b66f37a07792e594176e4), [`e19bd16`](https://github.com/ckb-devrel/ccc/commit/e19bd16c1375bb66fa5b66f37a07792e594176e4), [`e19bd16`](https://github.com/ckb-devrel/ccc/commit/e19bd16c1375bb66fa5b66f37a07792e594176e4), [`e19bd16`](https://github.com/ckb-devrel/ccc/commit/e19bd16c1375bb66fa5b66f37a07792e594176e4), [`e19bd16`](https://github.com/ckb-devrel/ccc/commit/e19bd16c1375bb66fa5b66f37a07792e594176e4)]:
|
|
10
|
+
- @ckb-ccc/core@1.7.0
|
|
9
11
|
|
|
10
12
|
## 1.0.12
|
|
11
13
|
|
|
12
14
|
### Patch Changes
|
|
13
15
|
|
|
14
|
-
- [`
|
|
16
|
+
- [#155](https://github.com/ckb-devrel/ccc/pull/155) [`7bed665`](https://github.com/ckb-devrel/ccc/commit/7bed665f6c9444b37893f1c6c8c3cbca344a6ca4) Thanks [@wendychaung](https://github.com/wendychaung)! - fix: update window.rei.ckb
|
|
15
17
|
|
|
16
|
-
- Updated dependencies [[`
|
|
17
|
-
- @ckb-ccc/core@1.
|
|
18
|
+
- Updated dependencies [[`80e605d`](https://github.com/ckb-devrel/ccc/commit/80e605d0645e87b4e8b5be85c63322f7a3926e38), [`8c7e000`](https://github.com/ckb-devrel/ccc/commit/8c7e00069a276ac58afa4737623e95656d4852c5), [`732ad59`](https://github.com/ckb-devrel/ccc/commit/732ad59f13ea2cd47003033e30b310b8ff26f058), [`90b6e9f`](https://github.com/ckb-devrel/ccc/commit/90b6e9fee543b6ee16b96e27d6f86ff33fc57029), [`815fb4d`](https://github.com/ckb-devrel/ccc/commit/815fb4da3432b889b848eb70943d725988fe611d), [`def62a0`](https://github.com/ckb-devrel/ccc/commit/def62a08bf908c6a21fe91c8db2c60848a2ada52), [`d584059`](https://github.com/ckb-devrel/ccc/commit/d584059644e8bcd3a0ea8b0314fdcbb68ee66013), [`f58d398`](https://github.com/ckb-devrel/ccc/commit/f58d3980f08da1f3fa19cee45aa50c8b293294ea), [`1e88ad8`](https://github.com/ckb-devrel/ccc/commit/1e88ad8743428b46b28fe790bd559b96df8a6ce4), [`6f10589`](https://github.com/ckb-devrel/ccc/commit/6f1058977e7aa113808fa74793f1ad5d672626d2), [`601a729`](https://github.com/ckb-devrel/ccc/commit/601a7291e877b39c4032c95fab421ed3d41404c2), [`074b4cd`](https://github.com/ckb-devrel/ccc/commit/074b4cd3b0cdc925dc9ef99e8146564a60646f1e), [`d7728d9`](https://github.com/ckb-devrel/ccc/commit/d7728d9edb46c9c5a2bfeb342fc68a8b1c0fec5d), [`ab195a0`](https://github.com/ckb-devrel/ccc/commit/ab195a024aeee5e21ed19d89c2cf1bf8d52bb380), [`29a2e22`](https://github.com/ckb-devrel/ccc/commit/29a2e223b902ed23523e4948ab3fca793f9e5b01)]:
|
|
19
|
+
- @ckb-ccc/core@1.6.0
|
|
18
20
|
|
|
19
21
|
## 1.0.11
|
|
20
22
|
|
package/dist/signersFactory.d.ts
CHANGED
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import { ccc } from "@ckb-ccc/core";
|
|
2
2
|
/**
|
|
3
3
|
* Retrieves the Rei signer if available.
|
|
4
|
-
* @param client - The client instance.
|
|
5
|
-
* @returns The Signer instance if the Rei provider is available, otherwise undefined.
|
|
4
|
+
* @param {ccc.Client} client - The client instance.
|
|
5
|
+
* @returns {Signer | undefined} The Signer instance if the Rei provider is available, otherwise undefined.
|
|
6
|
+
|
|
6
7
|
*/
|
|
7
8
|
export declare function getReiSigners(client: ccc.Client): ccc.SignerInfo[];
|
|
8
9
|
//# sourceMappingURL=signersFactory.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"signersFactory.d.ts","sourceRoot":"","sources":["../src/signersFactory.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,eAAe,CAAC;AAIpC
|
|
1
|
+
{"version":3,"file":"signersFactory.d.ts","sourceRoot":"","sources":["../src/signersFactory.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,eAAe,CAAC;AAIpC;;;;;GAKG;AACH,wBAAgB,aAAa,CAAC,MAAM,EAAE,GAAG,CAAC,MAAM,GAAG,GAAG,CAAC,UAAU,EAAE,CAYlE"}
|
package/dist/signersFactory.js
CHANGED
|
@@ -1,17 +1,18 @@
|
|
|
1
1
|
import { ReiSigner } from "./signer.js";
|
|
2
2
|
/**
|
|
3
3
|
* Retrieves the Rei signer if available.
|
|
4
|
-
* @param client - The client instance.
|
|
5
|
-
* @returns The Signer instance if the Rei provider is available, otherwise undefined.
|
|
4
|
+
* @param {ccc.Client} client - The client instance.
|
|
5
|
+
* @returns {Signer | undefined} The Signer instance if the Rei provider is available, otherwise undefined.
|
|
6
|
+
|
|
6
7
|
*/
|
|
7
8
|
export function getReiSigners(client) {
|
|
8
9
|
const windowRef = window;
|
|
9
|
-
if (typeof windowRef
|
|
10
|
+
if (typeof windowRef?.rei?.ckb === "undefined") {
|
|
10
11
|
return [];
|
|
11
12
|
}
|
|
12
13
|
return [
|
|
13
14
|
{
|
|
14
|
-
signer: new ReiSigner(client, windowRef.ckb),
|
|
15
|
+
signer: new ReiSigner(client, windowRef.rei.ckb),
|
|
15
16
|
name: "CKB",
|
|
16
17
|
},
|
|
17
18
|
];
|
|
@@ -15,13 +15,23 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (
|
|
|
15
15
|
}) : function(o, v) {
|
|
16
16
|
o["default"] = v;
|
|
17
17
|
});
|
|
18
|
-
var __importStar = (this && this.__importStar) || function (
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
};
|
|
18
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
19
|
+
var ownKeys = function(o) {
|
|
20
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
21
|
+
var ar = [];
|
|
22
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
23
|
+
return ar;
|
|
24
|
+
};
|
|
25
|
+
return ownKeys(o);
|
|
26
|
+
};
|
|
27
|
+
return function (mod) {
|
|
28
|
+
if (mod && mod.__esModule) return mod;
|
|
29
|
+
var result = {};
|
|
30
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
31
|
+
__setModuleDefault(result, mod);
|
|
32
|
+
return result;
|
|
33
|
+
};
|
|
34
|
+
})();
|
|
25
35
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
36
|
exports.ReiA = void 0;
|
|
27
37
|
exports.ReiA = __importStar(require("./advancedBarrel.js"));
|
package/dist.commonjs/index.js
CHANGED
|
@@ -15,13 +15,23 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (
|
|
|
15
15
|
}) : function(o, v) {
|
|
16
16
|
o["default"] = v;
|
|
17
17
|
});
|
|
18
|
-
var __importStar = (this && this.__importStar) || function (
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
};
|
|
18
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
19
|
+
var ownKeys = function(o) {
|
|
20
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
21
|
+
var ar = [];
|
|
22
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
23
|
+
return ar;
|
|
24
|
+
};
|
|
25
|
+
return ownKeys(o);
|
|
26
|
+
};
|
|
27
|
+
return function (mod) {
|
|
28
|
+
if (mod && mod.__esModule) return mod;
|
|
29
|
+
var result = {};
|
|
30
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
31
|
+
__setModuleDefault(result, mod);
|
|
32
|
+
return result;
|
|
33
|
+
};
|
|
34
|
+
})();
|
|
25
35
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
36
|
exports.Rei = void 0;
|
|
27
37
|
exports.Rei = __importStar(require("./barrel.js"));
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import { ccc } from "@ckb-ccc/core";
|
|
2
2
|
/**
|
|
3
3
|
* Retrieves the Rei signer if available.
|
|
4
|
-
* @param client - The client instance.
|
|
5
|
-
* @returns The Signer instance if the Rei provider is available, otherwise undefined.
|
|
4
|
+
* @param {ccc.Client} client - The client instance.
|
|
5
|
+
* @returns {Signer | undefined} The Signer instance if the Rei provider is available, otherwise undefined.
|
|
6
|
+
|
|
6
7
|
*/
|
|
7
8
|
export declare function getReiSigners(client: ccc.Client): ccc.SignerInfo[];
|
|
8
9
|
//# sourceMappingURL=signersFactory.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"signersFactory.d.ts","sourceRoot":"","sources":["../src/signersFactory.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,eAAe,CAAC;AAIpC
|
|
1
|
+
{"version":3,"file":"signersFactory.d.ts","sourceRoot":"","sources":["../src/signersFactory.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,eAAe,CAAC;AAIpC;;;;;GAKG;AACH,wBAAgB,aAAa,CAAC,MAAM,EAAE,GAAG,CAAC,MAAM,GAAG,GAAG,CAAC,UAAU,EAAE,CAYlE"}
|
|
@@ -4,17 +4,18 @@ exports.getReiSigners = getReiSigners;
|
|
|
4
4
|
const signer_js_1 = require("./signer.js");
|
|
5
5
|
/**
|
|
6
6
|
* Retrieves the Rei signer if available.
|
|
7
|
-
* @param client - The client instance.
|
|
8
|
-
* @returns The Signer instance if the Rei provider is available, otherwise undefined.
|
|
7
|
+
* @param {ccc.Client} client - The client instance.
|
|
8
|
+
* @returns {Signer | undefined} The Signer instance if the Rei provider is available, otherwise undefined.
|
|
9
|
+
|
|
9
10
|
*/
|
|
10
11
|
function getReiSigners(client) {
|
|
11
12
|
const windowRef = window;
|
|
12
|
-
if (typeof windowRef
|
|
13
|
+
if (typeof windowRef?.rei?.ckb === "undefined") {
|
|
13
14
|
return [];
|
|
14
15
|
}
|
|
15
16
|
return [
|
|
16
17
|
{
|
|
17
|
-
signer: new signer_js_1.ReiSigner(client, windowRef.ckb),
|
|
18
|
+
signer: new signer_js_1.ReiSigner(client, windowRef.rei.ckb),
|
|
18
19
|
name: "CKB",
|
|
19
20
|
},
|
|
20
21
|
];
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ckb-ccc/rei",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.15",
|
|
4
4
|
"description": "CCC - CKBer's Codebase. Common Chains Connector's support for Rei",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"private": false,
|
|
@@ -50,7 +50,7 @@
|
|
|
50
50
|
"access": "public"
|
|
51
51
|
},
|
|
52
52
|
"dependencies": {
|
|
53
|
-
"@ckb-ccc/core": "1.
|
|
53
|
+
"@ckb-ccc/core": "1.7.0"
|
|
54
54
|
},
|
|
55
55
|
"scripts": {
|
|
56
56
|
"build": "rimraf ./dist && rimraf ./dist.commonjs && tsc && tsc --project tsconfig.commonjs.json && copyfiles -u 2 misc/basedirs/**/* .",
|
package/src/signersFactory.ts
CHANGED
|
@@ -4,19 +4,19 @@ import { ReiSigner } from "./signer.js";
|
|
|
4
4
|
|
|
5
5
|
/**
|
|
6
6
|
* Retrieves the Rei signer if available.
|
|
7
|
-
* @param client - The client instance.
|
|
8
|
-
* @returns The Signer instance if the Rei provider is available, otherwise undefined.
|
|
7
|
+
* @param {ccc.Client} client - The client instance.
|
|
8
|
+
* @returns {Signer | undefined} The Signer instance if the Rei provider is available, otherwise undefined.
|
|
9
|
+
|
|
9
10
|
*/
|
|
10
11
|
export function getReiSigners(client: ccc.Client): ccc.SignerInfo[] {
|
|
11
|
-
const windowRef = window as {
|
|
12
|
+
const windowRef = window as { rei?: { ckb: Provider } };
|
|
12
13
|
|
|
13
|
-
if (typeof windowRef
|
|
14
|
+
if (typeof windowRef?.rei?.ckb === "undefined") {
|
|
14
15
|
return [];
|
|
15
16
|
}
|
|
16
|
-
|
|
17
17
|
return [
|
|
18
18
|
{
|
|
19
|
-
signer: new ReiSigner(client, windowRef.ckb),
|
|
19
|
+
signer: new ReiSigner(client, windowRef.rei.ckb),
|
|
20
20
|
name: "CKB",
|
|
21
21
|
},
|
|
22
22
|
];
|