@instadapp/avocado-base 0.0.0-dev.19925f5 → 0.0.0-dev.21292ef

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.
Files changed (107) hide show
  1. package/.github/workflows/npm-publish-dev.yml +2 -5
  2. package/.vscode/settings.json +68 -0
  3. package/abi/avoFactoryProxy.json +109 -0
  4. package/abi/balanceResolver.json +110 -0
  5. package/abi/erc20.json +350 -0
  6. package/abi/forwarder.json +1435 -0
  7. package/abi/gaslessWallet.json +289 -0
  8. package/abi/multisigAgnosticForwarder.json +938 -0
  9. package/abi/multisigForwarder.json +697 -0
  10. package/app.vue +27 -0
  11. package/assets/images/icons/arrow-left.svg +5 -0
  12. package/assets/images/icons/arrow-right.svg +5 -0
  13. package/assets/images/icons/avocado.svg +4 -0
  14. package/assets/images/icons/bridge-2.svg +3 -0
  15. package/assets/images/icons/bridge.svg +7 -0
  16. package/assets/images/icons/calendar.svg +8 -0
  17. package/assets/images/icons/change-threshold.svg +4 -0
  18. package/assets/images/icons/check-circle.svg +4 -0
  19. package/assets/images/icons/check.svg +3 -0
  20. package/assets/images/icons/chevron-down.svg +4 -0
  21. package/assets/images/icons/clipboard.svg +7 -0
  22. package/assets/images/icons/clock-circle.svg +5 -0
  23. package/assets/images/icons/copy.svg +12 -0
  24. package/assets/images/icons/cross-transfer.svg +7 -0
  25. package/assets/images/icons/dapp.svg +4 -0
  26. package/assets/images/icons/deploy.svg +12 -0
  27. package/assets/images/icons/error-circle.svg +6 -0
  28. package/assets/images/icons/exclamation-circle.svg +13 -0
  29. package/assets/images/icons/exclamation-octagon.svg +13 -0
  30. package/assets/images/icons/exclamation-triangle.svg +5 -0
  31. package/assets/images/icons/external-link.svg +6 -0
  32. package/assets/images/icons/eye.svg +4 -0
  33. package/assets/images/icons/flowers.svg +8 -0
  34. package/assets/images/icons/gas-emoji.svg +193 -0
  35. package/assets/images/icons/gas.svg +14 -0
  36. package/assets/images/icons/gift.svg +153 -0
  37. package/assets/images/icons/globe.svg +110 -0
  38. package/assets/images/icons/hamburger.svg +6 -0
  39. package/assets/images/icons/hammer.svg +5 -0
  40. package/assets/images/icons/info-2.svg +12 -0
  41. package/assets/images/icons/instadapp-pro.svg +4 -0
  42. package/assets/images/icons/logout.svg +3 -0
  43. package/assets/images/icons/moon.svg +3 -0
  44. package/assets/images/icons/multi-send.svg +7 -0
  45. package/assets/images/icons/network.svg +13 -0
  46. package/assets/images/icons/options.svg +5 -0
  47. package/assets/images/icons/permit-sign.svg +11 -0
  48. package/assets/images/icons/plus-circle.svg +6 -0
  49. package/assets/images/icons/plus.svg +5 -0
  50. package/assets/images/icons/power-off-bg.svg +24 -0
  51. package/assets/images/icons/power-off.svg +19 -0
  52. package/assets/images/icons/power-on.svg +19 -0
  53. package/assets/images/icons/qr.svg +20 -0
  54. package/assets/images/icons/question-circle.svg +14 -0
  55. package/assets/images/icons/refresh.svg +6 -0
  56. package/assets/images/icons/reject-proposal.svg +6 -0
  57. package/assets/images/icons/search.svg +12 -0
  58. package/assets/images/icons/stars.svg +4 -0
  59. package/assets/images/icons/sun.svg +3 -0
  60. package/assets/images/icons/transfer.svg +5 -0
  61. package/assets/images/icons/trash-2.svg +8 -0
  62. package/assets/images/icons/upgrade.svg +4 -0
  63. package/assets/images/icons/wave.svg +214 -0
  64. package/assets/images/icons/x.svg +5 -0
  65. package/components/ActionLogo.vue +42 -0
  66. package/components/ActionMetadata.vue +88 -0
  67. package/components/Address.vue +74 -0
  68. package/components/AuthorityAvatar.vue +37 -0
  69. package/components/ChainLogo.vue +14 -423
  70. package/components/CopyClipboard.vue +42 -0
  71. package/components/metadata/Bridge.vue +59 -0
  72. package/components/metadata/CrossTransfer.vue +76 -0
  73. package/components/metadata/GasTopup.vue +39 -0
  74. package/components/metadata/Permit2.vue +42 -0
  75. package/components/metadata/Signers.vue +19 -0
  76. package/components/metadata/Swap.vue +66 -0
  77. package/components/metadata/Transfer.vue +48 -0
  78. package/components.d.ts +13 -0
  79. package/contracts/AvoFactoryProxy.ts +302 -0
  80. package/contracts/BalanceResolver.ts +321 -0
  81. package/contracts/Erc20.ts +526 -0
  82. package/contracts/Forwarder.ts +1644 -0
  83. package/contracts/GaslessWallet.ts +660 -0
  84. package/contracts/MultisigAgnosticForwarder.ts +1423 -0
  85. package/contracts/MultisigForwarder.ts +859 -0
  86. package/contracts/common.ts +46 -0
  87. package/contracts/factories/AvoFactoryProxy__factory.ts +181 -0
  88. package/contracts/factories/BalanceResolver__factory.ts +212 -0
  89. package/contracts/factories/Erc20__factory.ts +368 -0
  90. package/contracts/factories/Forwarder__factory.ts +1456 -0
  91. package/contracts/factories/GaslessWallet__factory.ts +499 -0
  92. package/contracts/factories/MultisigAgnosticForwarder__factory.ts +2135 -0
  93. package/contracts/factories/MultisigForwarder__factory.ts +721 -0
  94. package/contracts/factories/index.ts +10 -0
  95. package/contracts/index.ts +18 -0
  96. package/eslint.config.mjs +20 -0
  97. package/nuxt.config.ts +23 -2
  98. package/package.json +24 -8
  99. package/server/utils/index.ts +2 -0
  100. package/utils/avocado.ts +2 -0
  101. package/utils/bignumber.ts +51 -0
  102. package/utils/formatter.ts +94 -0
  103. package/utils/helper.ts +62 -0
  104. package/utils/metadata.ts +694 -0
  105. package/utils/network.ts +560 -91
  106. package/utils/services.ts +21 -0
  107. package/utils/utils.d.ts +146 -16
@@ -0,0 +1,499 @@
1
+ /* Autogenerated file. Do not edit manually. */
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+
5
+ import { Contract, Signer, utils } from "ethers";
6
+ import type { Provider } from "@ethersproject/providers";
7
+ import type { GaslessWallet, GaslessWalletInterface } from "../GaslessWallet";
8
+
9
+ const _abi = [
10
+ {
11
+ inputs: [
12
+ {
13
+ internalType: "contract IGSWVersionsRegistry",
14
+ name: "gswVersionsRegistry_",
15
+ type: "address",
16
+ },
17
+ {
18
+ internalType: "address",
19
+ name: "gswForwarder_",
20
+ type: "address",
21
+ },
22
+ ],
23
+ stateMutability: "nonpayable",
24
+ type: "constructor",
25
+ },
26
+ {
27
+ inputs: [],
28
+ name: "GaslessSmartWallet__Expired",
29
+ type: "error",
30
+ },
31
+ {
32
+ inputs: [],
33
+ name: "GaslessSmartWallet__InvalidParams",
34
+ type: "error",
35
+ },
36
+ {
37
+ inputs: [],
38
+ name: "GaslessSmartWallet__InvalidSignature",
39
+ type: "error",
40
+ },
41
+ {
42
+ inputs: [],
43
+ name: "GaslessSmartWallet__Unauthorized",
44
+ type: "error",
45
+ },
46
+ {
47
+ inputs: [],
48
+ name: "SelfUpgradeable__Unauthorized",
49
+ type: "error",
50
+ },
51
+ {
52
+ anonymous: false,
53
+ inputs: [
54
+ {
55
+ indexed: true,
56
+ internalType: "address",
57
+ name: "source",
58
+ type: "address",
59
+ },
60
+ {
61
+ indexed: true,
62
+ internalType: "address",
63
+ name: "caller",
64
+ type: "address",
65
+ },
66
+ {
67
+ indexed: false,
68
+ internalType: "bytes",
69
+ name: "metadata",
70
+ type: "bytes",
71
+ },
72
+ ],
73
+ name: "CastExecuted",
74
+ type: "event",
75
+ },
76
+ {
77
+ anonymous: false,
78
+ inputs: [
79
+ {
80
+ indexed: true,
81
+ internalType: "address",
82
+ name: "source",
83
+ type: "address",
84
+ },
85
+ {
86
+ indexed: true,
87
+ internalType: "address",
88
+ name: "caller",
89
+ type: "address",
90
+ },
91
+ {
92
+ indexed: false,
93
+ internalType: "string",
94
+ name: "reason",
95
+ type: "string",
96
+ },
97
+ {
98
+ indexed: false,
99
+ internalType: "bytes",
100
+ name: "metadata",
101
+ type: "bytes",
102
+ },
103
+ ],
104
+ name: "CastFailed",
105
+ type: "event",
106
+ },
107
+ {
108
+ anonymous: false,
109
+ inputs: [
110
+ {
111
+ indexed: false,
112
+ internalType: "uint8",
113
+ name: "version",
114
+ type: "uint8",
115
+ },
116
+ ],
117
+ name: "Initialized",
118
+ type: "event",
119
+ },
120
+ {
121
+ anonymous: false,
122
+ inputs: [
123
+ {
124
+ indexed: true,
125
+ internalType: "address",
126
+ name: "gswImpl",
127
+ type: "address",
128
+ },
129
+ ],
130
+ name: "Upgraded",
131
+ type: "event",
132
+ },
133
+ {
134
+ inputs: [],
135
+ name: "ACTION_TYPE_HASH",
136
+ outputs: [
137
+ {
138
+ internalType: "bytes32",
139
+ name: "",
140
+ type: "bytes32",
141
+ },
142
+ ],
143
+ stateMutability: "view",
144
+ type: "function",
145
+ },
146
+ {
147
+ inputs: [],
148
+ name: "CAST_TYPE_HASH",
149
+ outputs: [
150
+ {
151
+ internalType: "bytes32",
152
+ name: "",
153
+ type: "bytes32",
154
+ },
155
+ ],
156
+ stateMutability: "view",
157
+ type: "function",
158
+ },
159
+ {
160
+ inputs: [],
161
+ name: "DEFAULT_CHAIN_ID",
162
+ outputs: [
163
+ {
164
+ internalType: "uint256",
165
+ name: "",
166
+ type: "uint256",
167
+ },
168
+ ],
169
+ stateMutability: "view",
170
+ type: "function",
171
+ },
172
+ {
173
+ inputs: [],
174
+ name: "DOMAIN_SEPARATOR_NAME",
175
+ outputs: [
176
+ {
177
+ internalType: "string",
178
+ name: "",
179
+ type: "string",
180
+ },
181
+ ],
182
+ stateMutability: "view",
183
+ type: "function",
184
+ },
185
+ {
186
+ inputs: [],
187
+ name: "DOMAIN_SEPARATOR_VERSION",
188
+ outputs: [
189
+ {
190
+ internalType: "string",
191
+ name: "",
192
+ type: "string",
193
+ },
194
+ ],
195
+ stateMutability: "view",
196
+ type: "function",
197
+ },
198
+ {
199
+ inputs: [],
200
+ name: "TYPE_HASH",
201
+ outputs: [
202
+ {
203
+ internalType: "bytes32",
204
+ name: "",
205
+ type: "bytes32",
206
+ },
207
+ ],
208
+ stateMutability: "view",
209
+ type: "function",
210
+ },
211
+ {
212
+ inputs: [
213
+ {
214
+ components: [
215
+ {
216
+ internalType: "address",
217
+ name: "target",
218
+ type: "address",
219
+ },
220
+ {
221
+ internalType: "bytes",
222
+ name: "data",
223
+ type: "bytes",
224
+ },
225
+ {
226
+ internalType: "uint256",
227
+ name: "value",
228
+ type: "uint256",
229
+ },
230
+ ],
231
+ internalType: "struct IGaslessSmartWallet.Action[]",
232
+ name: "actions_",
233
+ type: "tuple[]",
234
+ },
235
+ ],
236
+ name: "_callTargets",
237
+ outputs: [],
238
+ stateMutability: "payable",
239
+ type: "function",
240
+ },
241
+ {
242
+ inputs: [
243
+ {
244
+ components: [
245
+ {
246
+ internalType: "address",
247
+ name: "target",
248
+ type: "address",
249
+ },
250
+ {
251
+ internalType: "bytes",
252
+ name: "data",
253
+ type: "bytes",
254
+ },
255
+ {
256
+ internalType: "uint256",
257
+ name: "value",
258
+ type: "uint256",
259
+ },
260
+ ],
261
+ internalType: "struct IGaslessSmartWallet.Action[]",
262
+ name: "actions_",
263
+ type: "tuple[]",
264
+ },
265
+ {
266
+ internalType: "uint256",
267
+ name: "validUntil_",
268
+ type: "uint256",
269
+ },
270
+ {
271
+ internalType: "uint256",
272
+ name: "gas_",
273
+ type: "uint256",
274
+ },
275
+ {
276
+ internalType: "address",
277
+ name: "source_",
278
+ type: "address",
279
+ },
280
+ {
281
+ internalType: "bytes",
282
+ name: "metadata_",
283
+ type: "bytes",
284
+ },
285
+ {
286
+ internalType: "bytes",
287
+ name: "signature_",
288
+ type: "bytes",
289
+ },
290
+ ],
291
+ name: "cast",
292
+ outputs: [
293
+ {
294
+ internalType: "bool",
295
+ name: "success_",
296
+ type: "bool",
297
+ },
298
+ {
299
+ internalType: "string",
300
+ name: "revertReason_",
301
+ type: "string",
302
+ },
303
+ ],
304
+ stateMutability: "payable",
305
+ type: "function",
306
+ },
307
+ {
308
+ inputs: [],
309
+ name: "domainSeparatorV4",
310
+ outputs: [
311
+ {
312
+ internalType: "bytes32",
313
+ name: "",
314
+ type: "bytes32",
315
+ },
316
+ ],
317
+ stateMutability: "view",
318
+ type: "function",
319
+ },
320
+ {
321
+ inputs: [],
322
+ name: "gswForwarder",
323
+ outputs: [
324
+ {
325
+ internalType: "address",
326
+ name: "",
327
+ type: "address",
328
+ },
329
+ ],
330
+ stateMutability: "view",
331
+ type: "function",
332
+ },
333
+ {
334
+ inputs: [],
335
+ name: "gswNonce",
336
+ outputs: [
337
+ {
338
+ internalType: "uint256",
339
+ name: "",
340
+ type: "uint256",
341
+ },
342
+ ],
343
+ stateMutability: "view",
344
+ type: "function",
345
+ },
346
+ {
347
+ inputs: [],
348
+ name: "gswVersionsRegistry",
349
+ outputs: [
350
+ {
351
+ internalType: "contract IGSWVersionsRegistry",
352
+ name: "",
353
+ type: "address",
354
+ },
355
+ ],
356
+ stateMutability: "view",
357
+ type: "function",
358
+ },
359
+ {
360
+ inputs: [
361
+ {
362
+ internalType: "address",
363
+ name: "owner_",
364
+ type: "address",
365
+ },
366
+ ],
367
+ name: "initialize",
368
+ outputs: [],
369
+ stateMutability: "nonpayable",
370
+ type: "function",
371
+ },
372
+ {
373
+ inputs: [],
374
+ name: "owner",
375
+ outputs: [
376
+ {
377
+ internalType: "address",
378
+ name: "",
379
+ type: "address",
380
+ },
381
+ ],
382
+ stateMutability: "view",
383
+ type: "function",
384
+ },
385
+ {
386
+ inputs: [
387
+ {
388
+ internalType: "address",
389
+ name: "gswImpl_",
390
+ type: "address",
391
+ },
392
+ ],
393
+ name: "upgradeTo",
394
+ outputs: [],
395
+ stateMutability: "nonpayable",
396
+ type: "function",
397
+ },
398
+ {
399
+ inputs: [
400
+ {
401
+ internalType: "address",
402
+ name: "gswImpl_",
403
+ type: "address",
404
+ },
405
+ {
406
+ internalType: "bytes",
407
+ name: "data_",
408
+ type: "bytes",
409
+ },
410
+ {
411
+ internalType: "bool",
412
+ name: "forceCall_",
413
+ type: "bool",
414
+ },
415
+ ],
416
+ name: "upgradeToAndCall",
417
+ outputs: [],
418
+ stateMutability: "payable",
419
+ type: "function",
420
+ },
421
+ {
422
+ inputs: [
423
+ {
424
+ components: [
425
+ {
426
+ internalType: "address",
427
+ name: "target",
428
+ type: "address",
429
+ },
430
+ {
431
+ internalType: "bytes",
432
+ name: "data",
433
+ type: "bytes",
434
+ },
435
+ {
436
+ internalType: "uint256",
437
+ name: "value",
438
+ type: "uint256",
439
+ },
440
+ ],
441
+ internalType: "struct IGaslessSmartWallet.Action[]",
442
+ name: "actions_",
443
+ type: "tuple[]",
444
+ },
445
+ {
446
+ internalType: "uint256",
447
+ name: "validUntil_",
448
+ type: "uint256",
449
+ },
450
+ {
451
+ internalType: "uint256",
452
+ name: "gas_",
453
+ type: "uint256",
454
+ },
455
+ {
456
+ internalType: "address",
457
+ name: "source_",
458
+ type: "address",
459
+ },
460
+ {
461
+ internalType: "bytes",
462
+ name: "metadata_",
463
+ type: "bytes",
464
+ },
465
+ {
466
+ internalType: "bytes",
467
+ name: "signature_",
468
+ type: "bytes",
469
+ },
470
+ ],
471
+ name: "verify",
472
+ outputs: [
473
+ {
474
+ internalType: "bool",
475
+ name: "",
476
+ type: "bool",
477
+ },
478
+ ],
479
+ stateMutability: "view",
480
+ type: "function",
481
+ },
482
+ {
483
+ stateMutability: "payable",
484
+ type: "receive",
485
+ },
486
+ ] as const;
487
+
488
+ export class GaslessWallet__factory {
489
+ static readonly abi = _abi;
490
+ static createInterface(): GaslessWalletInterface {
491
+ return new utils.Interface(_abi) as GaslessWalletInterface;
492
+ }
493
+ static connect(
494
+ address: string,
495
+ signerOrProvider: Signer | Provider
496
+ ): GaslessWallet {
497
+ return new Contract(address, _abi, signerOrProvider) as GaslessWallet;
498
+ }
499
+ }