@show-karma/karma-gap-sdk 0.3.42 → 0.3.44
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/core/class/Attestation.d.ts +3 -2
- package/core/class/Attestation.js +11 -8
- package/core/class/GAP.d.ts +1 -1
- package/core/class/GapSchema.js +1 -0
- package/core/class/GraphQL/GapEasClient.d.ts +7 -7
- package/core/class/GraphQL/GapEasClient.js +60 -60
- package/core/class/Schema.d.ts +12 -3
- package/core/class/Schema.js +31 -10
- package/core/class/SchemaError.d.ts +2 -1
- package/core/class/SchemaError.js +4 -3
- package/core/class/contract/GapContract.d.ts +11 -6
- package/core/class/contract/GapContract.js +35 -6
- package/core/class/entities/Community.d.ts +2 -2
- package/core/class/entities/Community.js +9 -3
- package/core/class/entities/Grant.d.ts +11 -11
- package/core/class/entities/Grant.js +25 -21
- package/core/class/entities/GrantUpdate.d.ts +8 -2
- package/core/class/entities/GrantUpdate.js +29 -6
- package/core/class/entities/MemberOf.d.ts +2 -2
- package/core/class/entities/MemberOf.js +4 -2
- package/core/class/entities/Milestone.d.ts +14 -7
- package/core/class/entities/Milestone.js +60 -21
- package/core/class/entities/Project.d.ts +3 -3
- package/core/class/entities/Project.js +12 -7
- package/core/class/entities/ProjectImpact.d.ts +6 -2
- package/core/class/entities/ProjectImpact.js +23 -6
- package/core/class/entities/ProjectUpdate.d.ts +2 -2
- package/core/class/entities/ProjectUpdate.js +21 -5
- package/core/class/karma-indexer/api/types.d.ts +1 -0
- package/core/class/types/attestations.d.ts +8 -1
- package/core/consts.js +190 -46
- package/core/types.d.ts +9 -0
- package/package.json +1 -1
package/core/consts.js
CHANGED
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.AlloContracts = exports.alloSupportedNetworks = exports.MountEntities = exports.Networks = exports.zeroAddress = exports.nullResolver = exports.nullRef = exports.chainIdToNetwork = exports.useDefaultAttestation = void 0;
|
|
4
|
+
const oldStatusSchema = [
|
|
5
|
+
{ type: "string", name: "type", value: null },
|
|
6
|
+
{ type: "string", name: "reason", value: null },
|
|
7
|
+
];
|
|
4
8
|
/**
|
|
5
9
|
* Schemas that should use default EAS attestation
|
|
6
10
|
* instead of the custom contract.
|
|
@@ -48,14 +52,41 @@ exports.Networks = {
|
|
|
48
52
|
Community: "0x721c17b065dccc5c916e0c2708d0ef50f1810591b76d0402ff6fe5accbd8488f",
|
|
49
53
|
Details: "0x70a3f615f738fc6a4f56100692ada93d947c028b840940d97af7e7d6f0fa0577",
|
|
50
54
|
Grant: "0x12837231f48acbca4e1e7f4416f684f3353bd4d71d4f03a09d29e5ffa6f21a50",
|
|
51
|
-
GrantVerified: "
|
|
55
|
+
GrantVerified: "0xdc3f4d0938b1d029d825c01b3c53ad955e0ef3eabc1f57c1ebde90de2bf527ae",
|
|
52
56
|
MemberOf: "0x7fbb8a65924d8ad2ae12356e04b1418043e8361ba3b1b6c917de2e23df3ec81c",
|
|
53
|
-
MilestoneApproved: "
|
|
54
|
-
MilestoneCompleted: "
|
|
55
|
-
GrantUpdateStatus: "
|
|
57
|
+
MilestoneApproved: "0xdc3f4d0938b1d029d825c01b3c53ad955e0ef3eabc1f57c1ebde90de2bf527ae",
|
|
58
|
+
MilestoneCompleted: "0xdc3f4d0938b1d029d825c01b3c53ad955e0ef3eabc1f57c1ebde90de2bf527ae",
|
|
59
|
+
GrantUpdateStatus: "0xdc3f4d0938b1d029d825c01b3c53ad955e0ef3eabc1f57c1ebde90de2bf527ae",
|
|
56
60
|
Project: "0x5b873b6e7a16207b526dde366e8164e95bcda2f009272306519667c5e94d2191",
|
|
57
|
-
ProjectUpdateStatus: "
|
|
61
|
+
ProjectUpdateStatus: "0xdc3f4d0938b1d029d825c01b3c53ad955e0ef3eabc1f57c1ebde90de2bf527ae",
|
|
58
62
|
},
|
|
63
|
+
oldSchemas: [
|
|
64
|
+
{
|
|
65
|
+
name: "GrantVerified",
|
|
66
|
+
uid: "0x13adc8df8a7324b1651e8bcec948b3e2d4fcfa2a88a52136206cb9ea44836e93",
|
|
67
|
+
raw: oldStatusSchema
|
|
68
|
+
},
|
|
69
|
+
{
|
|
70
|
+
name: "MilestoneApproved",
|
|
71
|
+
uid: "0x13adc8df8a7324b1651e8bcec948b3e2d4fcfa2a88a52136206cb9ea44836e93",
|
|
72
|
+
raw: oldStatusSchema
|
|
73
|
+
},
|
|
74
|
+
{
|
|
75
|
+
name: "MilestoneCompleted",
|
|
76
|
+
uid: "0x13adc8df8a7324b1651e8bcec948b3e2d4fcfa2a88a52136206cb9ea44836e93",
|
|
77
|
+
raw: oldStatusSchema
|
|
78
|
+
},
|
|
79
|
+
{
|
|
80
|
+
name: "GrantUpdateStatus",
|
|
81
|
+
uid: "0x13adc8df8a7324b1651e8bcec948b3e2d4fcfa2a88a52136206cb9ea44836e93",
|
|
82
|
+
raw: oldStatusSchema
|
|
83
|
+
},
|
|
84
|
+
{
|
|
85
|
+
name: "ProjectUpdateStatus",
|
|
86
|
+
uid: "0x13adc8df8a7324b1651e8bcec948b3e2d4fcfa2a88a52136206cb9ea44836e93",
|
|
87
|
+
raw: oldStatusSchema
|
|
88
|
+
},
|
|
89
|
+
]
|
|
59
90
|
},
|
|
60
91
|
"optimism-sepolia": {
|
|
61
92
|
chainId: 11155420,
|
|
@@ -73,14 +104,41 @@ exports.Networks = {
|
|
|
73
104
|
Community: "0x314bb1c3c9b5311c1b813a3ad123b6ac5a03902b987795056dd2e4ff38e833ea",
|
|
74
105
|
Details: "0xd193e75f420a69910f98fa79cacdfd9d0dcbf5933edce8f8bde9a10bd204d996",
|
|
75
106
|
Grant: "0x181beb00ef05cf99caa2e4192369232f210c2764f26e238d962112bf592e9cce",
|
|
76
|
-
GrantVerified: "
|
|
107
|
+
GrantVerified: "0x6f8e6a1394bdc398f8d93a99b0ecca326d04470a4f0ee5c379bb85a458a322e4",
|
|
77
108
|
MemberOf: "0x611f9655188f372e27dce116a803fa9081ca3e2907986368d54fcad538ca3853",
|
|
78
|
-
MilestoneApproved: "
|
|
79
|
-
MilestoneCompleted: "
|
|
80
|
-
GrantUpdateStatus: "
|
|
109
|
+
MilestoneApproved: "0x6f8e6a1394bdc398f8d93a99b0ecca326d04470a4f0ee5c379bb85a458a322e4",
|
|
110
|
+
MilestoneCompleted: "0x6f8e6a1394bdc398f8d93a99b0ecca326d04470a4f0ee5c379bb85a458a322e4",
|
|
111
|
+
GrantUpdateStatus: "0x6f8e6a1394bdc398f8d93a99b0ecca326d04470a4f0ee5c379bb85a458a322e4",
|
|
81
112
|
Project: "0xf9bbd118dd100459a7d093403af21c6e7f847fd7f331b7a4e6bfb94a1366bd76",
|
|
82
|
-
ProjectUpdateStatus: "
|
|
113
|
+
ProjectUpdateStatus: "0x6f8e6a1394bdc398f8d93a99b0ecca326d04470a4f0ee5c379bb85a458a322e4",
|
|
83
114
|
},
|
|
115
|
+
oldSchemas: [
|
|
116
|
+
{
|
|
117
|
+
name: "GrantVerified",
|
|
118
|
+
uid: "0xf9ec600d61d88614c863365a79715a7ba29781ec67643ffeb9222dd8873ee3fa",
|
|
119
|
+
raw: oldStatusSchema
|
|
120
|
+
},
|
|
121
|
+
{
|
|
122
|
+
name: "MilestoneApproved",
|
|
123
|
+
uid: "0xf9ec600d61d88614c863365a79715a7ba29781ec67643ffeb9222dd8873ee3fa",
|
|
124
|
+
raw: oldStatusSchema
|
|
125
|
+
},
|
|
126
|
+
{
|
|
127
|
+
name: "MilestoneCompleted",
|
|
128
|
+
uid: "0xf9ec600d61d88614c863365a79715a7ba29781ec67643ffeb9222dd8873ee3fa",
|
|
129
|
+
raw: oldStatusSchema
|
|
130
|
+
},
|
|
131
|
+
{
|
|
132
|
+
name: "GrantUpdateStatus",
|
|
133
|
+
uid: "0xf9ec600d61d88614c863365a79715a7ba29781ec67643ffeb9222dd8873ee3fa",
|
|
134
|
+
raw: oldStatusSchema
|
|
135
|
+
},
|
|
136
|
+
{
|
|
137
|
+
name: "ProjectUpdateStatus",
|
|
138
|
+
uid: "0xf9ec600d61d88614c863365a79715a7ba29781ec67643ffeb9222dd8873ee3fa",
|
|
139
|
+
raw: oldStatusSchema
|
|
140
|
+
},
|
|
141
|
+
]
|
|
84
142
|
},
|
|
85
143
|
arbitrum: {
|
|
86
144
|
chainId: 42161,
|
|
@@ -98,14 +156,41 @@ exports.Networks = {
|
|
|
98
156
|
Community: "0xc604f0661cfd522583835ed2b2c644b80e068139d287f93c7f1680888894bacc",
|
|
99
157
|
Details: "0x16bfe4783b7a9c743c401222c56a07ecb77ed42afc84b61ff1f62f5936c0b9d7",
|
|
100
158
|
Grant: "0xea02ab33f9f4c92ba02c9bb21614b7410b98c940a0d8eb8ad3a20204d8b4bda5",
|
|
101
|
-
GrantVerified: "
|
|
159
|
+
GrantVerified: "0x93391c496898c63995f23797835c8e0468be338f0dbc2df62edfd70856cde1d4",
|
|
102
160
|
MemberOf: "0x5f430aec9d04f0dcb3729775c5dfe10752e436469a7607f8c64ae44ef996e477",
|
|
103
|
-
MilestoneApproved: "
|
|
104
|
-
MilestoneCompleted: "
|
|
105
|
-
GrantUpdateStatus: "
|
|
161
|
+
MilestoneApproved: "0x93391c496898c63995f23797835c8e0468be338f0dbc2df62edfd70856cde1d4",
|
|
162
|
+
MilestoneCompleted: "0x93391c496898c63995f23797835c8e0468be338f0dbc2df62edfd70856cde1d4",
|
|
163
|
+
GrantUpdateStatus: "0x93391c496898c63995f23797835c8e0468be338f0dbc2df62edfd70856cde1d4",
|
|
106
164
|
Project: "0xac2a06e955a7e25e6729efe1a6532237e3435b21ccd3dc827ae3c94e624d25b3",
|
|
107
|
-
ProjectUpdateStatus: "
|
|
165
|
+
ProjectUpdateStatus: "0x93391c496898c63995f23797835c8e0468be338f0dbc2df62edfd70856cde1d4",
|
|
108
166
|
},
|
|
167
|
+
oldSchemas: [
|
|
168
|
+
{
|
|
169
|
+
name: "GrantVerified",
|
|
170
|
+
uid: "0xd25ccdfbf87659a9081681eb90598d8b944ed28544da7d57c3ccbe6e6422cc15",
|
|
171
|
+
raw: oldStatusSchema
|
|
172
|
+
},
|
|
173
|
+
{
|
|
174
|
+
name: "MilestoneApproved",
|
|
175
|
+
uid: "0xd25ccdfbf87659a9081681eb90598d8b944ed28544da7d57c3ccbe6e6422cc15",
|
|
176
|
+
raw: oldStatusSchema
|
|
177
|
+
},
|
|
178
|
+
{
|
|
179
|
+
name: "MilestoneCompleted",
|
|
180
|
+
uid: "0xd25ccdfbf87659a9081681eb90598d8b944ed28544da7d57c3ccbe6e6422cc15",
|
|
181
|
+
raw: oldStatusSchema
|
|
182
|
+
},
|
|
183
|
+
{
|
|
184
|
+
name: "GrantUpdateStatus",
|
|
185
|
+
uid: "0xd25ccdfbf87659a9081681eb90598d8b944ed28544da7d57c3ccbe6e6422cc15",
|
|
186
|
+
raw: oldStatusSchema
|
|
187
|
+
},
|
|
188
|
+
{
|
|
189
|
+
name: "ProjectUpdateStatus",
|
|
190
|
+
uid: "0xd25ccdfbf87659a9081681eb90598d8b944ed28544da7d57c3ccbe6e6422cc15",
|
|
191
|
+
raw: oldStatusSchema
|
|
192
|
+
},
|
|
193
|
+
]
|
|
109
194
|
},
|
|
110
195
|
sepolia: {
|
|
111
196
|
chainId: 11155111,
|
|
@@ -174,19 +259,46 @@ exports.Networks = {
|
|
|
174
259
|
Community: "0x3c2231024f4f17f3718b5bd9ed9ff29cc323dea5449f9ceba11a9888bfbdd0e1",
|
|
175
260
|
Details: "0x9895e82115987d8e3e02b35ced92e6a0509293890333f58f50ec291b34853dac",
|
|
176
261
|
Grant: "0x7afa603a89cee2d8f93d30007e2c64efddc6509fd76aa95d2ccd97b6e34acc71",
|
|
177
|
-
GrantVerified: "
|
|
262
|
+
GrantVerified: "0x80f0701853e862d920f87e8ae5b359a1625ad417a9523af2ed12bc3504b04088",
|
|
178
263
|
MemberOf: "0xb4186a2401f40a4c78768941ef9140e1fbe5fe595053a65d44f31d6df180b712",
|
|
179
|
-
MilestoneApproved: "
|
|
180
|
-
MilestoneCompleted: "
|
|
181
|
-
GrantUpdateStatus: "
|
|
264
|
+
MilestoneApproved: "0x80f0701853e862d920f87e8ae5b359a1625ad417a9523af2ed12bc3504b04088",
|
|
265
|
+
MilestoneCompleted: "0x80f0701853e862d920f87e8ae5b359a1625ad417a9523af2ed12bc3504b04088",
|
|
266
|
+
GrantUpdateStatus: "0x80f0701853e862d920f87e8ae5b359a1625ad417a9523af2ed12bc3504b04088",
|
|
182
267
|
Project: "0xf3f753b41e04d1052b5a5ec7624d1dfdb6c2da288a985120e477ddbcac071022",
|
|
183
|
-
ProjectUpdateStatus: "
|
|
268
|
+
ProjectUpdateStatus: "0x80f0701853e862d920f87e8ae5b359a1625ad417a9523af2ed12bc3504b04088",
|
|
184
269
|
},
|
|
270
|
+
oldSchemas: [
|
|
271
|
+
{
|
|
272
|
+
name: "GrantVerified",
|
|
273
|
+
uid: "0xf45fdf2c064073f0623416571c2746085d785cde5a57fd0696ff88bdf78bcbdc",
|
|
274
|
+
raw: oldStatusSchema
|
|
275
|
+
},
|
|
276
|
+
{
|
|
277
|
+
name: "MilestoneApproved",
|
|
278
|
+
uid: "0xf45fdf2c064073f0623416571c2746085d785cde5a57fd0696ff88bdf78bcbdc",
|
|
279
|
+
raw: oldStatusSchema
|
|
280
|
+
},
|
|
281
|
+
{
|
|
282
|
+
name: "MilestoneCompleted",
|
|
283
|
+
uid: "0xf45fdf2c064073f0623416571c2746085d785cde5a57fd0696ff88bdf78bcbdc",
|
|
284
|
+
raw: oldStatusSchema
|
|
285
|
+
},
|
|
286
|
+
{
|
|
287
|
+
name: "GrantUpdateStatus",
|
|
288
|
+
uid: "0xf45fdf2c064073f0623416571c2746085d785cde5a57fd0696ff88bdf78bcbdc",
|
|
289
|
+
raw: oldStatusSchema
|
|
290
|
+
},
|
|
291
|
+
{
|
|
292
|
+
name: "ProjectUpdateStatus",
|
|
293
|
+
uid: "0xf45fdf2c064073f0623416571c2746085d785cde5a57fd0696ff88bdf78bcbdc",
|
|
294
|
+
raw: oldStatusSchema
|
|
295
|
+
},
|
|
296
|
+
]
|
|
185
297
|
},
|
|
186
298
|
sei: {
|
|
187
299
|
chainId: 1329,
|
|
188
300
|
url: "https://sei.easscan.org/graphql",
|
|
189
|
-
rpcUrl: "https://
|
|
301
|
+
rpcUrl: "https://muddy-orbital-arrow.sei-pacific.quiknode.pro/594552c3ab4ed4106b40402c16dba137ab279d40",
|
|
190
302
|
contracts: {
|
|
191
303
|
eas: "0x391020888b0adBA584A67693458b374e4141f838",
|
|
192
304
|
schema: "0x80A4B50f549a8271e10A6C8e79172cb56f35fD57",
|
|
@@ -199,14 +311,41 @@ exports.Networks = {
|
|
|
199
311
|
Community: "0x57dee0b7e1aa8e5c6280c27fecf2edeb225f1b87b47e2750f9dc7eaebe57a2ba",
|
|
200
312
|
Details: "0x1b4365b92aa47de3f67cdfb53127518381c1e66e0d9e0f8a15bbfa7250950967",
|
|
201
313
|
Grant: "0xe9030dc574039832103dd5939f9dd214340602d2af4bbf1c8b2666e720ed0bf6",
|
|
202
|
-
GrantVerified: "
|
|
314
|
+
GrantVerified: "0xc3b9bee0be3a6ea92f76fa459922a088824e29798becdc82d81f6b2309442563",
|
|
203
315
|
MemberOf: "0xb7278b94cea2b9f1a8fdd1c4bb52ed66906516a0ff9d59d0f80daffcf147ea5d",
|
|
204
|
-
MilestoneApproved: "
|
|
205
|
-
MilestoneCompleted: "
|
|
206
|
-
GrantUpdateStatus: "
|
|
316
|
+
MilestoneApproved: "0xc3b9bee0be3a6ea92f76fa459922a088824e29798becdc82d81f6b2309442563",
|
|
317
|
+
MilestoneCompleted: "0xc3b9bee0be3a6ea92f76fa459922a088824e29798becdc82d81f6b2309442563",
|
|
318
|
+
GrantUpdateStatus: "0xc3b9bee0be3a6ea92f76fa459922a088824e29798becdc82d81f6b2309442563",
|
|
207
319
|
Project: "0xf6b89107f8096220051240b89a48abb66e0a23e529c914953b80f5a2bc5ea44c",
|
|
208
|
-
ProjectUpdateStatus: "
|
|
320
|
+
ProjectUpdateStatus: "0xc3b9bee0be3a6ea92f76fa459922a088824e29798becdc82d81f6b2309442563",
|
|
209
321
|
},
|
|
322
|
+
oldSchemas: [
|
|
323
|
+
{
|
|
324
|
+
name: "GrantVerified",
|
|
325
|
+
uid: "0x6edc90af92553109cfed1292a67a75b34e41880bd8a61e9d05db0473b69a2f9e",
|
|
326
|
+
raw: oldStatusSchema
|
|
327
|
+
},
|
|
328
|
+
{
|
|
329
|
+
name: "MilestoneApproved",
|
|
330
|
+
uid: "0x6edc90af92553109cfed1292a67a75b34e41880bd8a61e9d05db0473b69a2f9e",
|
|
331
|
+
raw: oldStatusSchema
|
|
332
|
+
},
|
|
333
|
+
{
|
|
334
|
+
name: "MilestoneCompleted",
|
|
335
|
+
uid: "0x6edc90af92553109cfed1292a67a75b34e41880bd8a61e9d05db0473b69a2f9e",
|
|
336
|
+
raw: oldStatusSchema
|
|
337
|
+
},
|
|
338
|
+
{
|
|
339
|
+
name: "GrantUpdateStatus",
|
|
340
|
+
uid: "0x6edc90af92553109cfed1292a67a75b34e41880bd8a61e9d05db0473b69a2f9e",
|
|
341
|
+
raw: oldStatusSchema
|
|
342
|
+
},
|
|
343
|
+
{
|
|
344
|
+
name: "ProjectUpdateStatus",
|
|
345
|
+
uid: "0x6edc90af92553109cfed1292a67a75b34e41880bd8a61e9d05db0473b69a2f9e",
|
|
346
|
+
raw: oldStatusSchema
|
|
347
|
+
},
|
|
348
|
+
]
|
|
210
349
|
},
|
|
211
350
|
"sei-testnet": {
|
|
212
351
|
chainId: 1328,
|
|
@@ -245,35 +384,41 @@ const MountEntities = (network) => ({
|
|
|
245
384
|
name: "Community",
|
|
246
385
|
schema: [{ type: "bool", name: "community", value: true }],
|
|
247
386
|
uid: network.schemas.Community,
|
|
387
|
+
oldSchemas: network.oldSchemas?.filter(s => s.name === "Community")?.map(s => ({ uid: s.uid, raw: s.raw }))
|
|
248
388
|
},
|
|
249
389
|
CommunityDetails: {
|
|
250
390
|
name: "CommunityDetails",
|
|
251
391
|
schema: DetailsSchema,
|
|
252
392
|
uid: network.schemas.Details,
|
|
253
393
|
references: "Community",
|
|
394
|
+
oldSchemas: network.oldSchemas?.filter(s => s.name === "CommunityDetails")?.map(s => ({ uid: s.uid, raw: s.raw }))
|
|
254
395
|
},
|
|
255
396
|
Project: {
|
|
256
397
|
name: "Project",
|
|
257
398
|
schema: [{ type: "bool", name: "project", value: true }],
|
|
258
399
|
uid: network.schemas.Project,
|
|
400
|
+
oldSchemas: network.oldSchemas?.filter(s => s.name === "Project")?.map(s => ({ uid: s.uid, raw: s.raw }))
|
|
259
401
|
},
|
|
260
402
|
ProjectDetails: {
|
|
261
403
|
name: "ProjectDetails",
|
|
262
404
|
schema: DetailsSchema,
|
|
263
405
|
uid: network.schemas.Details,
|
|
264
406
|
references: "Project",
|
|
407
|
+
oldSchemas: network.oldSchemas?.filter(s => s.name === "ProjectDetails")?.map(s => ({ uid: s.uid, raw: s.raw }))
|
|
265
408
|
},
|
|
266
409
|
MemberOf: {
|
|
267
410
|
name: "MemberOf",
|
|
268
411
|
schema: [{ type: "bool", name: "memberOf", value: true }],
|
|
269
412
|
uid: network.schemas.MemberOf,
|
|
270
413
|
references: "Project",
|
|
414
|
+
oldSchemas: network.oldSchemas?.filter(s => s.name === "MemberOf")?.map(s => ({ uid: s.uid, raw: s.raw }))
|
|
271
415
|
},
|
|
272
416
|
MemberDetails: {
|
|
273
417
|
name: "MemberDetails",
|
|
274
418
|
schema: DetailsSchema,
|
|
275
419
|
uid: network.schemas.Details,
|
|
276
420
|
references: "MemberOf",
|
|
421
|
+
oldSchemas: network.oldSchemas?.filter(s => s.name === "MemberDetails")?.map(s => ({ uid: s.uid, raw: s.raw }))
|
|
277
422
|
},
|
|
278
423
|
Grant: {
|
|
279
424
|
name: "Grant",
|
|
@@ -281,98 +426,97 @@ const MountEntities = (network) => ({
|
|
|
281
426
|
// schema: [{ type: "bool", name: "grant", value: true }],
|
|
282
427
|
uid: network.schemas.Grant,
|
|
283
428
|
references: "Project",
|
|
429
|
+
oldSchemas: network.oldSchemas?.filter(s => s.name === "Grant")?.map(s => ({ uid: s.uid, raw: s.raw }))
|
|
284
430
|
},
|
|
285
431
|
GrantDetails: {
|
|
286
432
|
name: "GrantDetails",
|
|
287
433
|
schema: DetailsSchema,
|
|
288
434
|
uid: network.schemas.Details,
|
|
289
435
|
references: "Grant",
|
|
436
|
+
oldSchemas: network.oldSchemas?.filter(s => s.name === "GrantDetails")?.map(s => ({ uid: s.uid, raw: s.raw }))
|
|
290
437
|
},
|
|
291
438
|
GrantVerified: {
|
|
292
439
|
name: "GrantVerified",
|
|
293
|
-
schema:
|
|
294
|
-
{ type: "string", name: "type", value: null },
|
|
295
|
-
{ type: "string", name: "reason", value: "" },
|
|
296
|
-
],
|
|
440
|
+
schema: DetailsSchema,
|
|
297
441
|
uid: network.schemas.GrantVerified,
|
|
298
442
|
references: "Grant",
|
|
443
|
+
oldSchemas: network.oldSchemas?.filter(s => s.name === "GrantVerified")?.map(s => ({ uid: s.uid, raw: s.raw }))
|
|
299
444
|
},
|
|
300
445
|
Milestone: {
|
|
301
446
|
name: "Milestone",
|
|
302
447
|
schema: DetailsSchema,
|
|
303
448
|
uid: network.schemas.Details,
|
|
304
449
|
references: "Grant",
|
|
450
|
+
oldSchemas: network.oldSchemas?.filter(s => s.name === "Milestone")?.map(s => ({ uid: s.uid, raw: s.raw }))
|
|
305
451
|
},
|
|
306
452
|
MilestoneApproved: {
|
|
307
453
|
name: "MilestoneApproved",
|
|
308
|
-
schema:
|
|
309
|
-
{ type: "string", name: "type", value: null },
|
|
310
|
-
{ type: "string", name: "reason", value: "" },
|
|
311
|
-
],
|
|
454
|
+
schema: DetailsSchema,
|
|
312
455
|
uid: network.schemas.MilestoneApproved,
|
|
313
456
|
references: "Milestone",
|
|
457
|
+
oldSchemas: network.oldSchemas?.filter(s => s.name === "MilestoneApproved")?.map(s => ({ uid: s.uid, raw: s.raw }))
|
|
314
458
|
},
|
|
315
459
|
MilestoneCompleted: {
|
|
316
460
|
name: "MilestoneCompleted",
|
|
317
|
-
schema:
|
|
318
|
-
{ type: "string", name: "type", value: null },
|
|
319
|
-
{ type: "string", name: "reason", value: "" },
|
|
320
|
-
],
|
|
461
|
+
schema: DetailsSchema,
|
|
321
462
|
uid: network.schemas.MilestoneCompleted,
|
|
322
463
|
references: "Milestone",
|
|
464
|
+
oldSchemas: network.oldSchemas?.filter(s => s.name === "MilestoneCompleted")?.map(s => ({ uid: s.uid, raw: s.raw }))
|
|
323
465
|
},
|
|
324
466
|
Details: {
|
|
325
467
|
schema: DetailsSchema,
|
|
326
468
|
name: " schema",
|
|
327
469
|
uid: network.schemas.Details,
|
|
470
|
+
oldSchemas: network.oldSchemas?.filter(s => s.name === "DetailsSchema")?.map(s => ({ uid: s.uid, raw: s.raw }))
|
|
328
471
|
},
|
|
329
472
|
ProjectImpact: {
|
|
330
473
|
name: "ProjectImpact",
|
|
331
474
|
schema: DetailsSchema,
|
|
332
475
|
uid: network.schemas.Details,
|
|
333
476
|
references: "Project",
|
|
477
|
+
oldSchemas: network.oldSchemas?.filter(s => s.name === "ProjectImpact")?.map(s => ({ uid: s.uid, raw: s.raw }))
|
|
334
478
|
},
|
|
335
479
|
GrantUpdate: {
|
|
336
480
|
name: "GrantUpdate",
|
|
337
481
|
schema: DetailsSchema,
|
|
338
482
|
uid: network.schemas.Details,
|
|
339
483
|
references: "Grant",
|
|
484
|
+
oldSchemas: network.oldSchemas?.filter(s => s.name === "GrantUpdate")?.map(s => ({ uid: s.uid, raw: s.raw }))
|
|
340
485
|
},
|
|
341
486
|
GrantUpdateStatus: {
|
|
342
487
|
name: "GrantUpdateStatus",
|
|
343
|
-
schema:
|
|
344
|
-
{ type: "string", name: "type", value: null },
|
|
345
|
-
{ type: "string", name: "reason", value: "" },
|
|
346
|
-
],
|
|
488
|
+
schema: DetailsSchema,
|
|
347
489
|
uid: network.schemas.GrantUpdateStatus,
|
|
348
490
|
references: "GrantUpdate",
|
|
491
|
+
oldSchemas: network.oldSchemas?.filter(s => s.name === "GrantUpdateStatus")?.map(s => ({ uid: s.uid, raw: s.raw }))
|
|
349
492
|
},
|
|
350
493
|
ProjectEndorsement: {
|
|
351
494
|
name: "ProjectEndorsement",
|
|
352
495
|
schema: DetailsSchema,
|
|
353
496
|
uid: network.schemas.Details,
|
|
354
497
|
references: "Project",
|
|
498
|
+
oldSchemas: network.oldSchemas?.filter(s => s.name === "ProjectEndorsement")?.map(s => ({ uid: s.uid, raw: s.raw }))
|
|
355
499
|
},
|
|
356
500
|
ProjectUpdate: {
|
|
357
501
|
name: "ProjectUpdate",
|
|
358
502
|
schema: DetailsSchema,
|
|
359
503
|
uid: network.schemas.Details,
|
|
360
504
|
references: "Project",
|
|
505
|
+
oldSchemas: network.oldSchemas?.filter(s => s.name === "ProjectUpdate")?.map(s => ({ uid: s.uid, raw: s.raw }))
|
|
361
506
|
},
|
|
362
507
|
ProjectUpdateStatus: {
|
|
363
508
|
name: "ProjectUpdateStatus",
|
|
364
|
-
schema:
|
|
365
|
-
{ type: "string", name: "type", value: null },
|
|
366
|
-
{ type: "string", name: "reason", value: "" },
|
|
367
|
-
],
|
|
509
|
+
schema: DetailsSchema,
|
|
368
510
|
uid: network.schemas.ProjectUpdateStatus,
|
|
369
511
|
references: "ProjectUpdate",
|
|
512
|
+
oldSchemas: network.oldSchemas?.filter(s => s.name === "ProjectUpdateStatus")?.map(s => ({ uid: s.uid, raw: s.raw }))
|
|
370
513
|
},
|
|
371
514
|
ProjectPointer: {
|
|
372
515
|
name: "ProjectPointer",
|
|
373
516
|
schema: DetailsSchema,
|
|
374
517
|
uid: network.schemas.Details,
|
|
375
518
|
references: "Project",
|
|
519
|
+
oldSchemas: network.oldSchemas?.filter(s => s.name === "ProjectPointer")?.map(s => ({ uid: s.uid, raw: s.raw }))
|
|
376
520
|
},
|
|
377
521
|
});
|
|
378
522
|
exports.MountEntities = MountEntities;
|
package/core/types.d.ts
CHANGED
|
@@ -10,6 +10,10 @@ export interface SchemaInterface<T extends string = string> {
|
|
|
10
10
|
references?: T;
|
|
11
11
|
uid: Hex;
|
|
12
12
|
revocable?: boolean;
|
|
13
|
+
oldSchemas?: {
|
|
14
|
+
uid: string;
|
|
15
|
+
raw: SchemaItem[];
|
|
16
|
+
}[];
|
|
13
17
|
}
|
|
14
18
|
export interface MultiRevokeArgs {
|
|
15
19
|
uid: Hex;
|
|
@@ -71,6 +75,11 @@ export interface EASNetworkConfig {
|
|
|
71
75
|
* A tuple containing the schema name and it's UID for that network
|
|
72
76
|
*/
|
|
73
77
|
schemas: Record<TResolvedSchemaNames, Hex>;
|
|
78
|
+
oldSchemas?: {
|
|
79
|
+
name: string;
|
|
80
|
+
uid: string;
|
|
81
|
+
raw: SchemaItem[];
|
|
82
|
+
}[];
|
|
74
83
|
}
|
|
75
84
|
export type IGapSchema = SchemaInterface<TSchemaName>;
|
|
76
85
|
export type JSONStr = string;
|