@frak-labs/nexus-sdk 0.0.7 → 0.0.9
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/README.md +7 -6
- package/dist/{chunk-JXQKTLEE.cjs → chunk-AYZHGMEV.cjs} +14 -14
- package/dist/{chunk-DI2REDPX.js → chunk-PDR3CF3P.js} +19 -11
- package/dist/{chunk-OXP3VK26.js → chunk-SZUN32YC.js} +1 -1
- package/dist/{chunk-5QWG35A2.js → chunk-VK7GPKK4.js} +9 -0
- package/dist/{chunk-3LF3FGI6.cjs → chunk-X4JNNWJ4.cjs} +23 -15
- package/dist/{chunk-2XUJYDD3.cjs → chunk-ZOLP2FJZ.cjs} +9 -0
- package/dist/{client-DWLJ8zR-.d.ts → client-BwzXSgqQ.d.cts} +32 -3
- package/dist/{client-DWLJ8zR-.d.cts → client-BwzXSgqQ.d.ts} +32 -3
- package/dist/core/actions/index.cjs +5 -3
- package/dist/core/actions/index.d.cts +21 -5
- package/dist/core/actions/index.d.ts +21 -5
- package/dist/core/actions/index.js +4 -2
- package/dist/core/index.cjs +3 -3
- package/dist/core/index.d.cts +2 -2
- package/dist/core/index.d.ts +2 -2
- package/dist/core/index.js +2 -2
- package/dist/react/index.cjs +148 -18
- package/dist/react/index.d.cts +25 -11
- package/dist/react/index.d.ts +25 -11
- package/dist/react/index.js +146 -16
- package/dist/{watchUnlockStatus-B4kRztOM.d.cts → watchUnlockStatus-DXClCYH9.d.cts} +8 -3
- package/dist/{watchUnlockStatus--7dFtOJr.d.ts → watchUnlockStatus-WJxoDliF.d.ts} +8 -3
- package/package.json +2 -2
|
@@ -1,18 +1,21 @@
|
|
|
1
1
|
import { Hex } from 'viem';
|
|
2
|
-
import { N as NexusClient, A as ArticleUnlockStatusReturnType } from './client-
|
|
2
|
+
import { N as NexusClient, A as ArticleUnlockStatusReturnType } from './client-BwzXSgqQ.js';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* Type used to get the unlock options
|
|
6
6
|
*/
|
|
7
7
|
type GetUnlockOptionsParams = {
|
|
8
8
|
articleId: Hex;
|
|
9
|
+
contentId: Hex;
|
|
9
10
|
};
|
|
10
11
|
/**
|
|
11
12
|
* Function used to fetch the unlock option for the given client
|
|
12
13
|
* @param client
|
|
13
14
|
* @param articleId
|
|
15
|
+
* @param contentId
|
|
14
16
|
*/
|
|
15
|
-
declare function getArticleUnlockOptions(client: NexusClient, { articleId }: GetUnlockOptionsParams): Promise<Readonly<{
|
|
17
|
+
declare function getArticleUnlockOptions(client: NexusClient, { articleId, contentId }: GetUnlockOptionsParams): Promise<Readonly<{
|
|
18
|
+
frkBalanceAsHex?: `0x${string}` | undefined;
|
|
16
19
|
prices: {
|
|
17
20
|
index: number;
|
|
18
21
|
unlockDurationInSec: number;
|
|
@@ -26,13 +29,15 @@ declare function getArticleUnlockOptions(client: NexusClient, { articleId }: Get
|
|
|
26
29
|
*/
|
|
27
30
|
type WatchUnlockStatusParams = {
|
|
28
31
|
articleId: Hex;
|
|
32
|
+
contentId: Hex;
|
|
29
33
|
};
|
|
30
34
|
/**
|
|
31
35
|
* Function used to watch a current article unlock status
|
|
32
36
|
* @param client
|
|
33
37
|
* @param articleId
|
|
38
|
+
* @param contentId
|
|
34
39
|
* @param callback
|
|
35
40
|
*/
|
|
36
|
-
declare function watchUnlockStatus(client: NexusClient, { articleId }: WatchUnlockStatusParams, callback: (status: ArticleUnlockStatusReturnType) => void): Promise<void>;
|
|
41
|
+
declare function watchUnlockStatus(client: NexusClient, { articleId, contentId }: WatchUnlockStatusParams, callback: (status: ArticleUnlockStatusReturnType) => void): Promise<void>;
|
|
37
42
|
|
|
38
43
|
export { type GetUnlockOptionsParams as G, type WatchUnlockStatusParams as W, getArticleUnlockOptions as g, watchUnlockStatus as w };
|
package/package.json
CHANGED
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
"url": "https://twitter.com/QNivelais"
|
|
12
12
|
}
|
|
13
13
|
],
|
|
14
|
-
"version": "0.0.
|
|
14
|
+
"version": "0.0.9",
|
|
15
15
|
"description": "Nexus Wallet client SDK, helping any person to interact with the Frak wallet, and require the unlock of a premium article within the Frak ecosystem.",
|
|
16
16
|
"repository": "https://github.com/frak-id/wallet",
|
|
17
17
|
"homepage": "https://docs.frak.id/wallet-sdk",
|
|
@@ -72,7 +72,7 @@
|
|
|
72
72
|
"js-sha256": "^0.11.0"
|
|
73
73
|
},
|
|
74
74
|
"devDependencies": {
|
|
75
|
-
"@tanstack/react-query": ">=5.
|
|
75
|
+
"@tanstack/react-query": ">=5.32.0",
|
|
76
76
|
"@types/node": "^20",
|
|
77
77
|
"tsup": "^8.0.2",
|
|
78
78
|
"typescript": "^5"
|