@functionland/react-native-fula 1.13.1 → 1.14.0
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/android/.gradle/7.5.1/checksums/checksums.lock +0 -0
- package/android/.gradle/7.5.1/checksums/md5-checksums.bin +0 -0
- package/android/.gradle/7.5.1/checksums/sha1-checksums.bin +0 -0
- package/android/.gradle/7.5.1/fileHashes/fileHashes.lock +0 -0
- package/android/.gradle/buildOutputCleanup/buildOutputCleanup.lock +0 -0
- package/android/.gradle/buildOutputCleanup/outputFiles.bin +0 -0
- package/android/.idea/gradle.xml +1 -1
- package/android/.idea/misc.xml +2 -1
- package/android/.idea/sonarlint/issuestore/2/a/2afbb999f001938c88fa43fc2ef52abf0f8213e4 +0 -0
- package/android/.idea/sonarlint/issuestore/2/e/2e09eb0f0df666781fdff057a0af6101364ebe2f +0 -0
- package/android/.idea/sonarlint/issuestore/6/2/62149c3f7c3a14d7a77778e558d274e8c00a5585 +0 -0
- package/android/.idea/sonarlint/issuestore/8/0/80a78d662b0659428eb880336106c3c5fc3f0714 +0 -0
- package/android/.idea/sonarlint/issuestore/d/2/d2865ef8fc01c40e9fd82977fde2c8378fad0b12 +0 -0
- package/android/.idea/sonarlint/issuestore/f/b/fbe448ebfc3eb2d4e308f6b8b043666f5b57235e +0 -0
- package/android/.idea/sonarlint/issuestore/index.pb +13 -0
- package/android/.idea/sonarlint/securityhotspotstore/2/a/2afbb999f001938c88fa43fc2ef52abf0f8213e4 +0 -0
- package/android/.idea/sonarlint/securityhotspotstore/2/e/2e09eb0f0df666781fdff057a0af6101364ebe2f +0 -0
- package/android/.idea/sonarlint/securityhotspotstore/6/2/62149c3f7c3a14d7a77778e558d274e8c00a5585 +0 -0
- package/android/.idea/sonarlint/securityhotspotstore/8/0/80a78d662b0659428eb880336106c3c5fc3f0714 +0 -0
- package/android/.idea/sonarlint/securityhotspotstore/d/2/d2865ef8fc01c40e9fd82977fde2c8378fad0b12 +0 -0
- package/android/.idea/sonarlint/securityhotspotstore/f/b/fbe448ebfc3eb2d4e308f6b8b043666f5b57235e +0 -0
- package/android/.idea/sonarlint/securityhotspotstore/index.pb +13 -0
- package/android/build.gradle +70 -70
- package/android/src/main/java/land/fx/fula/FulaModule.java +1460 -1438
- package/lib/commonjs/protocols/chain-api.js +46 -8
- package/lib/commonjs/protocols/chain-api.js.map +1 -1
- package/lib/module/protocols/chain-api.js +48 -8
- package/lib/module/protocols/chain-api.js.map +1 -1
- package/package.json +157 -157
- package/src/protocols/chain-api.ts +127 -80
|
@@ -11,7 +11,7 @@ const types = {
|
|
|
11
11
|
FulaPoolPool: _apiLookup.default.FulaPoolPool
|
|
12
12
|
};
|
|
13
13
|
const init = async function () {
|
|
14
|
-
let wsAddress = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'wss://
|
|
14
|
+
let wsAddress = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'wss://node3.functionyard.fx.land';
|
|
15
15
|
const provider = new _api.WsProvider(wsAddress);
|
|
16
16
|
const api = await _api.ApiPromise.create({
|
|
17
17
|
types,
|
|
@@ -27,8 +27,46 @@ const disconnectApi = async api => {
|
|
|
27
27
|
await api.disconnect();
|
|
28
28
|
};
|
|
29
29
|
|
|
30
|
-
/*
|
|
31
|
-
|
|
30
|
+
/*
|
|
31
|
+
createAccount: This function takes a seed and returns am account
|
|
32
|
+
*/
|
|
33
|
+
/*export const uploadManifest = async (
|
|
34
|
+
api: ApiPromise | undefined,
|
|
35
|
+
seed: string,
|
|
36
|
+
manifest: typeof EventTypes.FunctionlandFulaCall._enum.upload_manifest
|
|
37
|
+
): Promise<BType.ManifestUploadResponse> => {
|
|
38
|
+
console.log('uploadManifest in react-native started');
|
|
39
|
+
try {
|
|
40
|
+
if (api === undefined) {
|
|
41
|
+
api = await init();
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
// Simple transaction
|
|
45
|
+
const keyring = new Keyring({ type: 'sr25519' });
|
|
46
|
+
const userKey = keyring.addFromUri(seed, { name: 'account' });
|
|
47
|
+
console.log(
|
|
48
|
+
`${userKey.meta.name}: has address ${userKey.address} with publicKey [${userKey.publicKey}]`
|
|
49
|
+
);
|
|
50
|
+
const submitExtrinsic = await api.tx.manifest.upload(manifest);
|
|
51
|
+
const unsub = await submitExtrinsic
|
|
52
|
+
.signAndSend(userKey, ({ status, events }) => {
|
|
53
|
+
if (status.isInBlock || status.isFinalized) {
|
|
54
|
+
console.log(events);
|
|
55
|
+
unsub();
|
|
56
|
+
return Promise.resolve({ success: true });
|
|
57
|
+
}
|
|
58
|
+
})
|
|
59
|
+
.catch((error) => {
|
|
60
|
+
console.log(':( transaction failed', error);
|
|
61
|
+
return Promise.reject(error);
|
|
62
|
+
});
|
|
63
|
+
} catch (err) {
|
|
64
|
+
return Promise.reject(err);
|
|
65
|
+
}
|
|
66
|
+
};*/
|
|
67
|
+
|
|
68
|
+
/*
|
|
69
|
+
listPools: This function takes start index and length and returns a promise of an object that contains a list of pools. Each pool in the list contains the poolID, owner, poolName, parent, and participants of the pool
|
|
32
70
|
*/
|
|
33
71
|
exports.disconnectApi = disconnectApi;
|
|
34
72
|
const listPools = async function (api) {
|
|
@@ -36,7 +74,7 @@ const listPools = async function (api) {
|
|
|
36
74
|
let length = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 10;
|
|
37
75
|
console.log('listPools in react-native started');
|
|
38
76
|
try {
|
|
39
|
-
if (api
|
|
77
|
+
if (api === undefined) {
|
|
40
78
|
api = await init();
|
|
41
79
|
}
|
|
42
80
|
const pools = {
|
|
@@ -63,14 +101,14 @@ const listPools = async function (api) {
|
|
|
63
101
|
}
|
|
64
102
|
};
|
|
65
103
|
|
|
66
|
-
/*
|
|
67
|
-
checkJoinRequest: This function takes poolId and AccontId and returns a promise of an object that contains request to the pools.
|
|
68
|
-
*/
|
|
104
|
+
/*
|
|
105
|
+
checkJoinRequest: This function takes poolId and AccontId and returns a promise of an object that contains request to the pools.
|
|
106
|
+
*/
|
|
69
107
|
exports.listPools = listPools;
|
|
70
108
|
const checkJoinRequest = async (api, poolId, accountId) => {
|
|
71
109
|
console.log('checkJoinRequest in react-native started');
|
|
72
110
|
try {
|
|
73
|
-
if (api
|
|
111
|
+
if (api === undefined) {
|
|
74
112
|
api = await init();
|
|
75
113
|
}
|
|
76
114
|
const poolRequest = await api.query.pool.poolRequests(poolId, accountId);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["types","FulaPoolPool","EventTypes","init","wsAddress","provider","WsProvider","api","ApiPromise","create","catch","err","console","log","Promise","reject","disconnectApi","disconnect","listPools","start","length","undefined","pools","lastPoolId","query","pool","finalReturnedId","Number","toHuman","i","poolInfo","formattedPoolInfo","JSON","parse","stringify","push","resolve","checkJoinRequest","poolId","accountId","poolRequest","poolRequests","formattedPoolRequest"],"sources":["chain-api.ts"],"sourcesContent":["import { default as EventTypes } from '../interfaces/api-lookup';\
|
|
1
|
+
{"version":3,"names":["types","FulaPoolPool","EventTypes","init","wsAddress","provider","WsProvider","api","ApiPromise","create","catch","err","console","log","Promise","reject","disconnectApi","disconnect","listPools","start","length","undefined","pools","lastPoolId","query","pool","finalReturnedId","Number","toHuman","i","poolInfo","formattedPoolInfo","JSON","parse","stringify","push","resolve","checkJoinRequest","poolId","accountId","poolRequest","poolRequests","formattedPoolRequest"],"sources":["chain-api.ts"],"sourcesContent":["import { default as EventTypes } from '../interfaces/api-lookup';\n\nimport { ApiPromise, WsProvider } from '@polkadot/api';\n//import { Keyring } from '@polkadot/keyring';\nimport type * as BType from '../types/blockchain';\n\nconst types = {\n FulaPoolPool: EventTypes.FulaPoolPool,\n};\n\nexport const init = async (\n wsAddress: string = 'wss://node3.functionyard.fx.land'\n): Promise<ApiPromise> => {\n const provider = new WsProvider(wsAddress);\n const api = await ApiPromise.create({ types, provider }).catch((err) => {\n console.log(err);\n return Promise.reject(err);\n });\n return api;\n};\n\nexport const disconnectApi = async (api: ApiPromise): Promise<void> => {\n await api.disconnect();\n};\n\n/*\n createAccount: This function takes a seed and returns am account\n*/\n/*export const uploadManifest = async (\n api: ApiPromise | undefined,\n seed: string,\n manifest: typeof EventTypes.FunctionlandFulaCall._enum.upload_manifest\n): Promise<BType.ManifestUploadResponse> => {\n console.log('uploadManifest in react-native started');\n try {\n if (api === undefined) {\n api = await init();\n }\n\n // Simple transaction\n const keyring = new Keyring({ type: 'sr25519' });\n const userKey = keyring.addFromUri(seed, { name: 'account' });\n console.log(\n `${userKey.meta.name}: has address ${userKey.address} with publicKey [${userKey.publicKey}]`\n );\n const submitExtrinsic = await api.tx.manifest.upload(manifest);\n const unsub = await submitExtrinsic\n .signAndSend(userKey, ({ status, events }) => {\n if (status.isInBlock || status.isFinalized) {\n console.log(events);\n unsub();\n return Promise.resolve({ success: true });\n }\n })\n .catch((error) => {\n console.log(':( transaction failed', error);\n return Promise.reject(error);\n });\n } catch (err) {\n return Promise.reject(err);\n }\n};*/\n\n/*\n listPools: This function takes start index and length and returns a promise of an object that contains a list of pools. Each pool in the list contains the poolID, owner, poolName, parent, and participants of the pool\n */\nexport const listPools = async (\n api: ApiPromise | undefined,\n start: number = 1,\n length: number = 10\n): Promise<BType.PoolListResponse> => {\n console.log('listPools in react-native started');\n try {\n if (api === undefined) {\n api = await init();\n }\n const pools: BType.PoolListResponse = { pools: [] };\n const lastPoolId = await api.query.pool.lastPoolId();\n let finalReturnedId: number = Number(lastPoolId.toHuman());\n if (Number(lastPoolId.toHuman()) > start + length) {\n finalReturnedId = start + length;\n }\n for (let i = start; i <= finalReturnedId; i++) {\n const poolInfo = await api.query.pool.pools(i).catch((err) => {\n console.log(err);\n return Promise.reject(err);\n });\n if (poolInfo != null) {\n let formattedPoolInfo: BType.Pool = JSON.parse(\n JSON.stringify(poolInfo.toHuman())\n );\n pools.pools.push(formattedPoolInfo);\n }\n }\n return Promise.resolve(pools);\n } catch (err) {\n return Promise.reject(err);\n }\n};\n\n/*\n checkJoinRequest: This function takes poolId and AccontId and returns a promise of an object that contains request to the pools.\n */\nexport const checkJoinRequest = async (\n api: ApiPromise | undefined,\n poolId: number,\n accountId: string\n): Promise<BType.PoolRequest | null> => {\n console.log('checkJoinRequest in react-native started');\n try {\n if (api === undefined) {\n api = await init();\n }\n\n const poolRequest = await api.query.pool.poolRequests(poolId, accountId);\n\n if (poolRequest != null) {\n let formattedPoolRequest: BType.PoolRequest = JSON.parse(\n JSON.stringify(poolRequest.toHuman())\n );\n return Promise.resolve(formattedPoolRequest);\n }\n return Promise.resolve(null);\n } catch (err) {\n return Promise.reject(err);\n }\n};\n"],"mappings":";;;;;;AAAA;AAEA;AAAuD;AAIvD,MAAMA,KAAK,GAAG;EACZC,YAAY,EAAEC,kBAAU,CAACD;AAC3B,CAAC;AAEM,MAAME,IAAI,GAAG,kBAEM;EAAA,IADxBC,SAAiB,uEAAG,kCAAkC;EAEtD,MAAMC,QAAQ,GAAG,IAAIC,eAAU,CAACF,SAAS,CAAC;EAC1C,MAAMG,GAAG,GAAG,MAAMC,eAAU,CAACC,MAAM,CAAC;IAAET,KAAK;IAAEK;EAAS,CAAC,CAAC,CAACK,KAAK,CAAEC,GAAG,IAAK;IACtEC,OAAO,CAACC,GAAG,CAACF,GAAG,CAAC;IAChB,OAAOG,OAAO,CAACC,MAAM,CAACJ,GAAG,CAAC;EAC5B,CAAC,CAAC;EACF,OAAOJ,GAAG;AACZ,CAAC;AAAC;AAEK,MAAMS,aAAa,GAAG,MAAOT,GAAe,IAAoB;EACrE,MAAMA,GAAG,CAACU,UAAU,EAAE;AACxB,CAAC;;AAED;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AAFA;AAGO,MAAMC,SAAS,GAAG,gBACvBX,GAA2B,EAGS;EAAA,IAFpCY,KAAa,uEAAG,C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F,CAAC;;AAED;AACA;AACA;AAFA;AAGO,MAAM0B,gBAAgB,GAAG,OAC9B9B,GAA2B,EAC3B+B,MAAc,EACdC,SAAiB,KACqB;EACtC3B,OAAO,CAACC,GAAG,CAAC,0CAA0C,CAAC;EACvD,IAAI;IACF,IAAIN,GAAG,KAAKc,SAAS,EAAE;MACrBd,GAAG,GAAG,MAAMJ,IAAI,EAAE;IACpB;IAEA,MAAMqC,WAAW,GAAG,MAAMjC,GAAG,CAACiB,KAAK,CAACC,IAAI,CAACgB,YAAY,CAACH,MAAM,EAAEC,SAAS,CAAC;IAExE,IAAIC,WAAW,IAAI,IAAI,EAAE;MACvB,IAAIE,oBAAuC,GAAGV,IAAI,CAACC,KAAK,CACtDD,IAAI,CAACE,SAAS,CAACM,WAAW,CAACZ,OAAO,EAAE,CAAC,CACtC;MACD,OAAOd,OAAO,CAACsB,OAAO,CAACM,oBAAoB,CAAC;IAC9C;IACA,OAAO5B,OAAO,CAACsB,OAAO,CAAC,IAAI,CAAC;EAC9B,CAAC,CAAC,OAAOzB,GAAG,EAAE;IACZ,OAAOG,OAAO,CAACC,MAAM,CAACJ,GAAG,CAAC;EAC5B;AACF,CAAC;AAAC"}
|
|
@@ -1,10 +1,12 @@
|
|
|
1
1
|
import { default as EventTypes } from '../interfaces/api-lookup';
|
|
2
2
|
import { ApiPromise, WsProvider } from '@polkadot/api';
|
|
3
|
+
//import { Keyring } from '@polkadot/keyring';
|
|
4
|
+
|
|
3
5
|
const types = {
|
|
4
6
|
FulaPoolPool: EventTypes.FulaPoolPool
|
|
5
7
|
};
|
|
6
8
|
export const init = async function () {
|
|
7
|
-
let wsAddress = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'wss://
|
|
9
|
+
let wsAddress = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'wss://node3.functionyard.fx.land';
|
|
8
10
|
const provider = new WsProvider(wsAddress);
|
|
9
11
|
const api = await ApiPromise.create({
|
|
10
12
|
types,
|
|
@@ -19,15 +21,53 @@ export const disconnectApi = async api => {
|
|
|
19
21
|
await api.disconnect();
|
|
20
22
|
};
|
|
21
23
|
|
|
22
|
-
/*
|
|
23
|
-
|
|
24
|
+
/*
|
|
25
|
+
createAccount: This function takes a seed and returns am account
|
|
26
|
+
*/
|
|
27
|
+
/*export const uploadManifest = async (
|
|
28
|
+
api: ApiPromise | undefined,
|
|
29
|
+
seed: string,
|
|
30
|
+
manifest: typeof EventTypes.FunctionlandFulaCall._enum.upload_manifest
|
|
31
|
+
): Promise<BType.ManifestUploadResponse> => {
|
|
32
|
+
console.log('uploadManifest in react-native started');
|
|
33
|
+
try {
|
|
34
|
+
if (api === undefined) {
|
|
35
|
+
api = await init();
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
// Simple transaction
|
|
39
|
+
const keyring = new Keyring({ type: 'sr25519' });
|
|
40
|
+
const userKey = keyring.addFromUri(seed, { name: 'account' });
|
|
41
|
+
console.log(
|
|
42
|
+
`${userKey.meta.name}: has address ${userKey.address} with publicKey [${userKey.publicKey}]`
|
|
43
|
+
);
|
|
44
|
+
const submitExtrinsic = await api.tx.manifest.upload(manifest);
|
|
45
|
+
const unsub = await submitExtrinsic
|
|
46
|
+
.signAndSend(userKey, ({ status, events }) => {
|
|
47
|
+
if (status.isInBlock || status.isFinalized) {
|
|
48
|
+
console.log(events);
|
|
49
|
+
unsub();
|
|
50
|
+
return Promise.resolve({ success: true });
|
|
51
|
+
}
|
|
52
|
+
})
|
|
53
|
+
.catch((error) => {
|
|
54
|
+
console.log(':( transaction failed', error);
|
|
55
|
+
return Promise.reject(error);
|
|
56
|
+
});
|
|
57
|
+
} catch (err) {
|
|
58
|
+
return Promise.reject(err);
|
|
59
|
+
}
|
|
60
|
+
};*/
|
|
61
|
+
|
|
62
|
+
/*
|
|
63
|
+
listPools: This function takes start index and length and returns a promise of an object that contains a list of pools. Each pool in the list contains the poolID, owner, poolName, parent, and participants of the pool
|
|
24
64
|
*/
|
|
25
65
|
export const listPools = async function (api) {
|
|
26
66
|
let start = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 1;
|
|
27
67
|
let length = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 10;
|
|
28
68
|
console.log('listPools in react-native started');
|
|
29
69
|
try {
|
|
30
|
-
if (api
|
|
70
|
+
if (api === undefined) {
|
|
31
71
|
api = await init();
|
|
32
72
|
}
|
|
33
73
|
const pools = {
|
|
@@ -54,13 +94,13 @@ export const listPools = async function (api) {
|
|
|
54
94
|
}
|
|
55
95
|
};
|
|
56
96
|
|
|
57
|
-
/*
|
|
58
|
-
checkJoinRequest: This function takes poolId and AccontId and returns a promise of an object that contains request to the pools.
|
|
59
|
-
*/
|
|
97
|
+
/*
|
|
98
|
+
checkJoinRequest: This function takes poolId and AccontId and returns a promise of an object that contains request to the pools.
|
|
99
|
+
*/
|
|
60
100
|
export const checkJoinRequest = async (api, poolId, accountId) => {
|
|
61
101
|
console.log('checkJoinRequest in react-native started');
|
|
62
102
|
try {
|
|
63
|
-
if (api
|
|
103
|
+
if (api === undefined) {
|
|
64
104
|
api = await init();
|
|
65
105
|
}
|
|
66
106
|
const poolRequest = await api.query.pool.poolRequests(poolId, accountId);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["default","EventTypes","ApiPromise","WsProvider","types","FulaPoolPool","init","wsAddress","provider","api","create","catch","err","console","log","Promise","reject","disconnectApi","disconnect","listPools","start","length","undefined","pools","lastPoolId","query","pool","finalReturnedId","Number","toHuman","i","poolInfo","formattedPoolInfo","JSON","parse","stringify","push","resolve","checkJoinRequest","poolId","accountId","poolRequest","poolRequests","formattedPoolRequest"],"sources":["chain-api.ts"],"sourcesContent":["import { default as EventTypes } from '../interfaces/api-lookup';\
|
|
1
|
+
{"version":3,"names":["default","EventTypes","ApiPromise","WsProvider","types","FulaPoolPool","init","wsAddress","provider","api","create","catch","err","console","log","Promise","reject","disconnectApi","disconnect","listPools","start","length","undefined","pools","lastPoolId","query","pool","finalReturnedId","Number","toHuman","i","poolInfo","formattedPoolInfo","JSON","parse","stringify","push","resolve","checkJoinRequest","poolId","accountId","poolRequest","poolRequests","formattedPoolRequest"],"sources":["chain-api.ts"],"sourcesContent":["import { default as EventTypes } from '../interfaces/api-lookup';\n\nimport { ApiPromise, WsProvider } from '@polkadot/api';\n//import { Keyring } from '@polkadot/keyring';\nimport type * as BType from '../types/blockchain';\n\nconst types = {\n FulaPoolPool: EventTypes.FulaPoolPool,\n};\n\nexport const init = async (\n wsAddress: string = 'wss://node3.functionyard.fx.land'\n): Promise<ApiPromise> => {\n const provider = new WsProvider(wsAddress);\n const api = await ApiPromise.create({ types, provider }).catch((err) => {\n console.log(err);\n return Promise.reject(err);\n });\n return api;\n};\n\nexport const disconnectApi = async (api: ApiPromise): Promise<void> => {\n await api.disconnect();\n};\n\n/*\n createAccount: This function takes a seed and returns am account\n*/\n/*export const uploadManifest = async (\n api: ApiPromise | undefined,\n seed: string,\n manifest: typeof EventTypes.FunctionlandFulaCall._enum.upload_manifest\n): Promise<BType.ManifestUploadResponse> => {\n console.log('uploadManifest in react-native started');\n try {\n if (api === undefined) {\n api = await init();\n }\n\n // Simple transaction\n const keyring = new Keyring({ type: 'sr25519' });\n const userKey = keyring.addFromUri(seed, { name: 'account' });\n console.log(\n `${userKey.meta.name}: has address ${userKey.address} with publicKey [${userKey.publicKey}]`\n );\n const submitExtrinsic = await api.tx.manifest.upload(manifest);\n const unsub = await submitExtrinsic\n .signAndSend(userKey, ({ status, events }) => {\n if (status.isInBlock || status.isFinalized) {\n console.log(events);\n unsub();\n return Promise.resolve({ success: true });\n }\n })\n .catch((error) => {\n console.log(':( transaction failed', error);\n return Promise.reject(error);\n });\n } catch (err) {\n return Promise.reject(err);\n }\n};*/\n\n/*\n listPools: This function takes start index and length and returns a promise of an object that contains a list of pools. Each pool in the list contains the poolID, owner, poolName, parent, and participants of the pool\n */\nexport const listPools = async (\n api: ApiPromise | undefined,\n start: number = 1,\n length: number = 10\n): Promise<BType.PoolListResponse> => {\n console.log('listPools in react-native started');\n try {\n if (api === undefined) {\n api = await init();\n }\n const pools: BType.PoolListResponse = { pools: [] };\n const lastPoolId = await api.query.pool.lastPoolId();\n let finalReturnedId: number = Number(lastPoolId.toHuman());\n if (Number(lastPoolId.toHuman()) > start + length) {\n finalReturnedId = start + length;\n }\n for (let i = start; i <= finalReturnedId; i++) {\n const poolInfo = await api.query.pool.pools(i).catch((err) => {\n console.log(err);\n return Promise.reject(err);\n });\n if (poolInfo != null) {\n let formattedPoolInfo: BType.Pool = JSON.parse(\n JSON.stringify(poolInfo.toHuman())\n );\n pools.pools.push(formattedPoolInfo);\n }\n }\n return Promise.resolve(pools);\n } catch (err) {\n return Promise.reject(err);\n }\n};\n\n/*\n checkJoinRequest: This function takes poolId and AccontId and returns a promise of an object that contains request to the pools.\n */\nexport const checkJoinRequest = async (\n api: ApiPromise | undefined,\n poolId: number,\n accountId: string\n): Promise<BType.PoolRequest | null> => {\n console.log('checkJoinRequest in react-native started');\n try {\n if (api === undefined) {\n api = await init();\n }\n\n const poolRequest = await api.query.pool.poolRequests(poolId, accountId);\n\n if (poolRequest != null) {\n let formattedPoolRequest: BType.PoolRequest = JSON.parse(\n JSON.stringify(poolRequest.toHuman())\n );\n return Promise.resolve(formattedPoolRequest);\n }\n return Promise.resolve(null);\n } catch (err) {\n return Promise.reject(err);\n }\n};\n"],"mappings":"AAAA,SAASA,OAAO,IAAIC,UAAU,QAAQ,0BAA0B;AAEhE,SAASC,UAAU,EAAEC,UAAU,QAAQ,eAAe;AACtD;;AAGA,MAAMC,KAAK,GAAG;EACZC,YAAY,EAAEJ,UAAU,CAACI;AAC3B,CAAC;AAED,OAAO,MAAMC,IAAI,GAAG,kBAEM;EAAA,IADxBC,SAAiB,uEAAG,kCAAkC;EAEtD,MAAMC,QAAQ,GAAG,IAAIL,UAAU,CAACI,SAAS,CAAC;EAC1C,MAAME,GAAG,GAAG,MAAMP,UAAU,CAACQ,MAAM,CAAC;IAAEN,KAAK;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EAAE;IACZ,OAAOG,OAAO,CAACC,MAAM,CAACJ,GAAG,CAAC;EAC5B;AACF,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,157 +1,157 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "@functionland/react-native-fula",
|
|
3
|
-
"version": "1.
|
|
4
|
-
"description": "This package is a bridge to use the Fula libp2p protocols in the react-native which is using wnfs",
|
|
5
|
-
"main": "lib/commonjs/index",
|
|
6
|
-
"module": "lib/module/index",
|
|
7
|
-
"types": "lib/typescript/index.d.ts",
|
|
8
|
-
"react-native": "src/index",
|
|
9
|
-
"source": "src/index",
|
|
10
|
-
"files": [
|
|
11
|
-
"src",
|
|
12
|
-
"lib",
|
|
13
|
-
"android",
|
|
14
|
-
"ios",
|
|
15
|
-
"cpp",
|
|
16
|
-
"!example/",
|
|
17
|
-
"react-native-fula.podspec",
|
|
18
|
-
"!lib/typescript/example",
|
|
19
|
-
"!android/build",
|
|
20
|
-
"!ios/build",
|
|
21
|
-
"!**/__tests__",
|
|
22
|
-
"!**/__fixtures__",
|
|
23
|
-
"!**/__mocks__"
|
|
24
|
-
],
|
|
25
|
-
"scripts": {
|
|
26
|
-
"test": "jest",
|
|
27
|
-
"typescript": "tsc --noEmit",
|
|
28
|
-
"lint": "eslint \"**/*.{js,ts,tsx}\"",
|
|
29
|
-
"prepare": "bob build",
|
|
30
|
-
"release": "release-it",
|
|
31
|
-
"example": "set NODE_OPTIONS='' && yarn --cwd example",
|
|
32
|
-
"pods": "cd example && pod-install --quiet",
|
|
33
|
-
"bootstrap": "yarn example && yarn && yarn pods"
|
|
34
|
-
},
|
|
35
|
-
"keywords": [
|
|
36
|
-
"react-native",
|
|
37
|
-
"ios",
|
|
38
|
-
"android"
|
|
39
|
-
],
|
|
40
|
-
"repository": "https://github.com/functionland/react-native-fula",
|
|
41
|
-
"author": "Ehsan Shariati <ehsan6sha@gmail.com> (https://github.com/ehsan6sha)",
|
|
42
|
-
"license": "MIT",
|
|
43
|
-
"bugs": {
|
|
44
|
-
"url": "https://github.com/functionland/react-native-fula/issues"
|
|
45
|
-
},
|
|
46
|
-
"homepage": "https://github.com/functionland/react-native-fula#readme",
|
|
47
|
-
"publishConfig": {
|
|
48
|
-
"registry": "https://registry.npmjs.org"
|
|
49
|
-
},
|
|
50
|
-
"devDependencies": {
|
|
51
|
-
"@babel/plugin-proposal-export-namespace-from": "^7.16.7",
|
|
52
|
-
"@commitlint/config-conventional": "^11.0.0",
|
|
53
|
-
"@react-native-community/eslint-config": "^2.0.0",
|
|
54
|
-
"@release-it/conventional-changelog": "^2.0.0",
|
|
55
|
-
"@types/jest": "^26.0.0",
|
|
56
|
-
"@types/react": "^16.9.19",
|
|
57
|
-
"@types/react-native": "0.70.8",
|
|
58
|
-
"commitlint": "^11.0.0",
|
|
59
|
-
"eslint": "^7.2.0",
|
|
60
|
-
"eslint-config-prettier": "^7.0.0",
|
|
61
|
-
"eslint-plugin-prettier": "^3.1.3",
|
|
62
|
-
"husky": "^6.0.0",
|
|
63
|
-
"jest": "^26.0.1",
|
|
64
|
-
"pod-install": "^0.1.0",
|
|
65
|
-
"prettier": "^2.0.5",
|
|
66
|
-
"react": "^18.1.0",
|
|
67
|
-
"react-native": "0.70.6",
|
|
68
|
-
"react-native-builder-bob": "^0.18.0",
|
|
69
|
-
"release-it": "^14.2.2",
|
|
70
|
-
"typescript": "^4.1.3"
|
|
71
|
-
},
|
|
72
|
-
"peerDependencies": {
|
|
73
|
-
"@babel/core": "^7.0.0-0",
|
|
74
|
-
"@babel/preset-env": "^7.1.6",
|
|
75
|
-
"react": "*",
|
|
76
|
-
"react-native": "*"
|
|
77
|
-
},
|
|
78
|
-
"jest": {
|
|
79
|
-
"preset": "react-native",
|
|
80
|
-
"modulePathIgnorePatterns": [
|
|
81
|
-
"<rootDir>/example/node_modules",
|
|
82
|
-
"<rootDir>/lib/"
|
|
83
|
-
]
|
|
84
|
-
},
|
|
85
|
-
"commitlint": {
|
|
86
|
-
"extends": [
|
|
87
|
-
"@commitlint/config-conventional"
|
|
88
|
-
]
|
|
89
|
-
},
|
|
90
|
-
"release-it": {
|
|
91
|
-
"git": {
|
|
92
|
-
"commitMessage": "chore: release ${version}",
|
|
93
|
-
"tagName": "v${version}"
|
|
94
|
-
},
|
|
95
|
-
"npm": {
|
|
96
|
-
"publish": true
|
|
97
|
-
},
|
|
98
|
-
"github": {
|
|
99
|
-
"release": true
|
|
100
|
-
},
|
|
101
|
-
"plugins": {
|
|
102
|
-
"@release-it/conventional-changelog": {
|
|
103
|
-
"preset": "angular"
|
|
104
|
-
}
|
|
105
|
-
}
|
|
106
|
-
},
|
|
107
|
-
"eslintConfig": {
|
|
108
|
-
"root": true,
|
|
109
|
-
"extends": [
|
|
110
|
-
"@react-native-community",
|
|
111
|
-
"prettier"
|
|
112
|
-
],
|
|
113
|
-
"rules": {
|
|
114
|
-
"prettier/prettier": [
|
|
115
|
-
"error",
|
|
116
|
-
{
|
|
117
|
-
"quoteProps": "consistent",
|
|
118
|
-
"singleQuote": true,
|
|
119
|
-
"tabWidth": 2,
|
|
120
|
-
"trailingComma": "es5",
|
|
121
|
-
"useTabs": false
|
|
122
|
-
}
|
|
123
|
-
]
|
|
124
|
-
}
|
|
125
|
-
},
|
|
126
|
-
"eslintIgnore": [
|
|
127
|
-
"node_modules/",
|
|
128
|
-
"lib/"
|
|
129
|
-
],
|
|
130
|
-
"prettier": {
|
|
131
|
-
"quoteProps": "consistent",
|
|
132
|
-
"singleQuote": true,
|
|
133
|
-
"tabWidth": 2,
|
|
134
|
-
"trailingComma": "es5",
|
|
135
|
-
"useTabs": false
|
|
136
|
-
},
|
|
137
|
-
"react-native-builder-bob": {
|
|
138
|
-
"source": "src",
|
|
139
|
-
"output": "lib",
|
|
140
|
-
"targets": [
|
|
141
|
-
"commonjs",
|
|
142
|
-
"module",
|
|
143
|
-
[
|
|
144
|
-
"typescript",
|
|
145
|
-
{
|
|
146
|
-
"project": "tsconfig.build.json"
|
|
147
|
-
}
|
|
148
|
-
]
|
|
149
|
-
]
|
|
150
|
-
},
|
|
151
|
-
"dependencies": {
|
|
152
|
-
"@polkadot/api": "^9.11.3",
|
|
153
|
-
"@polkadot/keyring": "^10.2.6",
|
|
154
|
-
"@polkadot/util": "^10.2.6",
|
|
155
|
-
"@polkadot/util-crypto": "^10.2.6"
|
|
156
|
-
}
|
|
157
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"name": "@functionland/react-native-fula",
|
|
3
|
+
"version": "1.14.0",
|
|
4
|
+
"description": "This package is a bridge to use the Fula libp2p protocols in the react-native which is using wnfs",
|
|
5
|
+
"main": "lib/commonjs/index",
|
|
6
|
+
"module": "lib/module/index",
|
|
7
|
+
"types": "lib/typescript/index.d.ts",
|
|
8
|
+
"react-native": "src/index",
|
|
9
|
+
"source": "src/index",
|
|
10
|
+
"files": [
|
|
11
|
+
"src",
|
|
12
|
+
"lib",
|
|
13
|
+
"android",
|
|
14
|
+
"ios",
|
|
15
|
+
"cpp",
|
|
16
|
+
"!example/",
|
|
17
|
+
"react-native-fula.podspec",
|
|
18
|
+
"!lib/typescript/example",
|
|
19
|
+
"!android/build",
|
|
20
|
+
"!ios/build",
|
|
21
|
+
"!**/__tests__",
|
|
22
|
+
"!**/__fixtures__",
|
|
23
|
+
"!**/__mocks__"
|
|
24
|
+
],
|
|
25
|
+
"scripts": {
|
|
26
|
+
"test": "jest",
|
|
27
|
+
"typescript": "tsc --noEmit",
|
|
28
|
+
"lint": "eslint \"**/*.{js,ts,tsx}\"",
|
|
29
|
+
"prepare": "bob build",
|
|
30
|
+
"release": "release-it",
|
|
31
|
+
"example": "set NODE_OPTIONS='' && yarn --cwd example",
|
|
32
|
+
"pods": "cd example && pod-install --quiet",
|
|
33
|
+
"bootstrap": "yarn example && yarn && yarn pods"
|
|
34
|
+
},
|
|
35
|
+
"keywords": [
|
|
36
|
+
"react-native",
|
|
37
|
+
"ios",
|
|
38
|
+
"android"
|
|
39
|
+
],
|
|
40
|
+
"repository": "https://github.com/functionland/react-native-fula",
|
|
41
|
+
"author": "Ehsan Shariati <ehsan6sha@gmail.com> (https://github.com/ehsan6sha)",
|
|
42
|
+
"license": "MIT",
|
|
43
|
+
"bugs": {
|
|
44
|
+
"url": "https://github.com/functionland/react-native-fula/issues"
|
|
45
|
+
},
|
|
46
|
+
"homepage": "https://github.com/functionland/react-native-fula#readme",
|
|
47
|
+
"publishConfig": {
|
|
48
|
+
"registry": "https://registry.npmjs.org"
|
|
49
|
+
},
|
|
50
|
+
"devDependencies": {
|
|
51
|
+
"@babel/plugin-proposal-export-namespace-from": "^7.16.7",
|
|
52
|
+
"@commitlint/config-conventional": "^11.0.0",
|
|
53
|
+
"@react-native-community/eslint-config": "^2.0.0",
|
|
54
|
+
"@release-it/conventional-changelog": "^2.0.0",
|
|
55
|
+
"@types/jest": "^26.0.0",
|
|
56
|
+
"@types/react": "^16.9.19",
|
|
57
|
+
"@types/react-native": "0.70.8",
|
|
58
|
+
"commitlint": "^11.0.0",
|
|
59
|
+
"eslint": "^7.2.0",
|
|
60
|
+
"eslint-config-prettier": "^7.0.0",
|
|
61
|
+
"eslint-plugin-prettier": "^3.1.3",
|
|
62
|
+
"husky": "^6.0.0",
|
|
63
|
+
"jest": "^26.0.1",
|
|
64
|
+
"pod-install": "^0.1.0",
|
|
65
|
+
"prettier": "^2.0.5",
|
|
66
|
+
"react": "^18.1.0",
|
|
67
|
+
"react-native": "0.70.6",
|
|
68
|
+
"react-native-builder-bob": "^0.18.0",
|
|
69
|
+
"release-it": "^14.2.2",
|
|
70
|
+
"typescript": "^4.1.3"
|
|
71
|
+
},
|
|
72
|
+
"peerDependencies": {
|
|
73
|
+
"@babel/core": "^7.0.0-0",
|
|
74
|
+
"@babel/preset-env": "^7.1.6",
|
|
75
|
+
"react": "*",
|
|
76
|
+
"react-native": "*"
|
|
77
|
+
},
|
|
78
|
+
"jest": {
|
|
79
|
+
"preset": "react-native",
|
|
80
|
+
"modulePathIgnorePatterns": [
|
|
81
|
+
"<rootDir>/example/node_modules",
|
|
82
|
+
"<rootDir>/lib/"
|
|
83
|
+
]
|
|
84
|
+
},
|
|
85
|
+
"commitlint": {
|
|
86
|
+
"extends": [
|
|
87
|
+
"@commitlint/config-conventional"
|
|
88
|
+
]
|
|
89
|
+
},
|
|
90
|
+
"release-it": {
|
|
91
|
+
"git": {
|
|
92
|
+
"commitMessage": "chore: release ${version}",
|
|
93
|
+
"tagName": "v${version}"
|
|
94
|
+
},
|
|
95
|
+
"npm": {
|
|
96
|
+
"publish": true
|
|
97
|
+
},
|
|
98
|
+
"github": {
|
|
99
|
+
"release": true
|
|
100
|
+
},
|
|
101
|
+
"plugins": {
|
|
102
|
+
"@release-it/conventional-changelog": {
|
|
103
|
+
"preset": "angular"
|
|
104
|
+
}
|
|
105
|
+
}
|
|
106
|
+
},
|
|
107
|
+
"eslintConfig": {
|
|
108
|
+
"root": true,
|
|
109
|
+
"extends": [
|
|
110
|
+
"@react-native-community",
|
|
111
|
+
"prettier"
|
|
112
|
+
],
|
|
113
|
+
"rules": {
|
|
114
|
+
"prettier/prettier": [
|
|
115
|
+
"error",
|
|
116
|
+
{
|
|
117
|
+
"quoteProps": "consistent",
|
|
118
|
+
"singleQuote": true,
|
|
119
|
+
"tabWidth": 2,
|
|
120
|
+
"trailingComma": "es5",
|
|
121
|
+
"useTabs": false
|
|
122
|
+
}
|
|
123
|
+
]
|
|
124
|
+
}
|
|
125
|
+
},
|
|
126
|
+
"eslintIgnore": [
|
|
127
|
+
"node_modules/",
|
|
128
|
+
"lib/"
|
|
129
|
+
],
|
|
130
|
+
"prettier": {
|
|
131
|
+
"quoteProps": "consistent",
|
|
132
|
+
"singleQuote": true,
|
|
133
|
+
"tabWidth": 2,
|
|
134
|
+
"trailingComma": "es5",
|
|
135
|
+
"useTabs": false
|
|
136
|
+
},
|
|
137
|
+
"react-native-builder-bob": {
|
|
138
|
+
"source": "src",
|
|
139
|
+
"output": "lib",
|
|
140
|
+
"targets": [
|
|
141
|
+
"commonjs",
|
|
142
|
+
"module",
|
|
143
|
+
[
|
|
144
|
+
"typescript",
|
|
145
|
+
{
|
|
146
|
+
"project": "tsconfig.build.json"
|
|
147
|
+
}
|
|
148
|
+
]
|
|
149
|
+
]
|
|
150
|
+
},
|
|
151
|
+
"dependencies": {
|
|
152
|
+
"@polkadot/api": "^9.11.3",
|
|
153
|
+
"@polkadot/keyring": "^10.2.6",
|
|
154
|
+
"@polkadot/util": "^10.2.6",
|
|
155
|
+
"@polkadot/util-crypto": "^10.2.6"
|
|
156
|
+
}
|
|
157
|
+
}
|