@instadapp/avocado-base 0.0.0-dev.02731e3 → 0.0.0-dev.083a57a

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 (58) hide show
  1. package/abi/forwarder.json +1253 -149
  2. package/assets/images/icons/arrow-left.svg +5 -0
  3. package/assets/images/icons/arrow-right.svg +5 -0
  4. package/assets/images/icons/avocado.svg +4 -0
  5. package/assets/images/icons/bridge-2.svg +3 -0
  6. package/assets/images/icons/bridge.svg +7 -0
  7. package/assets/images/icons/calendar.svg +8 -0
  8. package/assets/images/icons/check-circle.svg +4 -0
  9. package/assets/images/icons/chevron-down.svg +4 -0
  10. package/assets/images/icons/clipboard.svg +7 -0
  11. package/assets/images/icons/clock-circle.svg +5 -0
  12. package/assets/images/icons/copy.svg +5 -0
  13. package/assets/images/icons/error-circle.svg +6 -0
  14. package/assets/images/icons/exclamation-circle.svg +13 -0
  15. package/assets/images/icons/exclamation-octagon.svg +13 -0
  16. package/assets/images/icons/exclamation-triangle.svg +5 -0
  17. package/assets/images/icons/external-link.svg +6 -0
  18. package/assets/images/icons/eye.svg +4 -0
  19. package/assets/images/icons/flowers.svg +8 -0
  20. package/assets/images/icons/gas-emoji.svg +193 -0
  21. package/assets/images/icons/gas.svg +7 -0
  22. package/assets/images/icons/gift.svg +153 -0
  23. package/assets/images/icons/globe.svg +110 -0
  24. package/assets/images/icons/hamburger.svg +6 -0
  25. package/assets/images/icons/logout.svg +3 -0
  26. package/assets/images/icons/moon.svg +3 -0
  27. package/assets/images/icons/network.svg +13 -0
  28. package/assets/images/icons/options.svg +5 -0
  29. package/assets/images/icons/plus.svg +5 -0
  30. package/assets/images/icons/power-off-bg.svg +24 -0
  31. package/assets/images/icons/power-off.svg +19 -0
  32. package/assets/images/icons/power-on.svg +19 -0
  33. package/assets/images/icons/qr.svg +20 -0
  34. package/assets/images/icons/question-circle.svg +14 -0
  35. package/assets/images/icons/refresh.svg +6 -0
  36. package/assets/images/icons/search.svg +12 -0
  37. package/assets/images/icons/sun.svg +3 -0
  38. package/assets/images/icons/wave.svg +214 -0
  39. package/assets/images/icons/x.svg +5 -0
  40. package/components/ActionMetadata.vue +53 -0
  41. package/components/ChainLogo.vue +1 -1
  42. package/components/metadata/Bridge.vue +39 -0
  43. package/components/metadata/CrossTransfer.vue +67 -0
  44. package/components/metadata/GasTopup.vue +33 -0
  45. package/components/metadata/Permit2.vue +37 -0
  46. package/components/metadata/Swap.vue +67 -0
  47. package/components/metadata/Transfer.vue +46 -0
  48. package/components.d.ts +13 -0
  49. package/contracts/Forwarder.ts +856 -2
  50. package/contracts/factories/Forwarder__factory.ts +816 -16
  51. package/nuxt.config.ts +17 -1
  52. package/package.json +6 -3
  53. package/utils/avocado.ts +2 -0
  54. package/utils/bignumber.ts +20 -0
  55. package/utils/metadata.ts +226 -138
  56. package/utils/network.ts +24 -23
  57. package/utils/services.ts +14 -0
  58. package/utils/utils.d.ts +20 -1
package/nuxt.config.ts CHANGED
@@ -1,4 +1,20 @@
1
1
  // https://nuxt.com/docs/api/configuration/nuxt-config
2
+ import ViteComponents from "unplugin-vue-components/vite";
3
+
2
4
  export default defineNuxtConfig({
3
- modules: ["@nuxtjs/tailwindcss"],
5
+ modules: ["@nuxtjs/tailwindcss", "nuxt-svgo", "@vueuse/nuxt"],
6
+ svgo: {
7
+ defaultImport: "component",
8
+ autoImportPath: "./assets/images/icons",
9
+ svgoConfig: {
10
+ plugins: ["prefixIds"],
11
+ },
12
+ },
13
+ vite: {
14
+ plugins: [
15
+ ViteComponents({
16
+ dts: true,
17
+ }),
18
+ ],
19
+ },
4
20
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@instadapp/avocado-base",
3
- "version": "0.0.0-dev.02731e3",
3
+ "version": "0.0.0-dev.083a57a",
4
4
  "type": "module",
5
5
  "main": "./nuxt.config.ts",
6
6
  "types": "global.d.ts",
@@ -16,11 +16,14 @@
16
16
  "@instadapp/avocado-dev": "npm:@instadapp/avocado@dev",
17
17
  "@nuxtjs/tailwindcss": "^6.6.5",
18
18
  "@typechain/ethers-v5": "^10.2.0",
19
- "nuxt": "^3.3.3",
19
+ "nuxt": "^3.6.1",
20
+ "nuxt-svgo": "^3.1.0",
20
21
  "rimraf": "^3.0.2",
21
- "typechain": "^8.1.1"
22
+ "typechain": "^8.1.1",
23
+ "unplugin-vue-components": "^0.25.1"
22
24
  },
23
25
  "dependencies": {
26
+ "@vueuse/nuxt": "^10.2.0",
24
27
  "bignumber.js": "^9.1.1",
25
28
  "ethers": "^5.7.2"
26
29
  }
package/utils/avocado.ts CHANGED
@@ -20,3 +20,5 @@ export const AVO_STAGING_DEPOSIT_ADDRESS =
20
20
  export const AVO_PROD_RPC_URL = "https://rpc.avocado.instadapp.io";
21
21
 
22
22
  export const AVO_STAGING_RPC_URL = "https://rpc.avocado.instad.app";
23
+
24
+ export const blockQueryURL = "https://blockquery.instadapp.io";
@@ -1,6 +1,8 @@
1
1
  import { BigNumber } from "bignumber.js";
2
2
  import { BigNumber as BN } from "ethers";
3
3
 
4
+ type CombinedBigNumber = BigNumber | string | number;
5
+
4
6
  export const toBN = (value: BigNumber.Value | BN) =>
5
7
  new BigNumber(BN.isBigNumber(value) ? value.toString() : value);
6
8
  export const isZero = (value: BigNumber.Value | BN) => toBN(value).isZero();
@@ -29,3 +31,21 @@ export const ensureValue = (value: any) => {
29
31
  export const max = (...args: BigNumber.Value[]) => {
30
32
  return BigNumber.max(...args);
31
33
  };
34
+
35
+ export function pow(value: CombinedBigNumber, exponent: string | number) {
36
+ return toBN(value).pow(toBN(exponent));
37
+ }
38
+
39
+ export function toWei(val: CombinedBigNumber, decimals: number): string {
40
+ const num = toBN(val);
41
+ const multiplier = pow(10, decimals);
42
+ return times(num, multiplier).toFixed(0);
43
+ }
44
+
45
+ export function fromWei(val: CombinedBigNumber, decimal = 18) {
46
+ return toBN(val).div(new BigNumber(10).pow(decimal));
47
+ }
48
+
49
+ export function abs(value: CombinedBigNumber) {
50
+ return toBN(value).abs();
51
+ }
package/utils/metadata.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  import { ethers, utils } from "ethers";
2
- import { Forwarder__factory } from "@/contracts";
2
+ import { Forwarder__factory } from "../contracts";
3
3
 
4
4
  const multiMetadataTypes = ["bytes[]"];
5
5
 
@@ -34,6 +34,7 @@ const actionMetadataTypes = {
34
34
  "gas-topup": ["uint256 amount", "address token", "address onBehalf"],
35
35
  upgrade: ["bytes32 version", "address walletImpl"],
36
36
  dapp: ["string name", "string url"],
37
+ auth: ["address address", "uint256 chainId", "bool remove"],
37
38
  deploy: [],
38
39
  permit2: [
39
40
  "address token",
@@ -41,6 +42,7 @@ const actionMetadataTypes = {
41
42
  "uint160 amount",
42
43
  "uint48 expiration",
43
44
  ],
45
+ "instadapp-pro": ["string castDetails"],
44
46
  };
45
47
 
46
48
  const encodeMetadata = (props: MetadataProps) => {
@@ -108,6 +110,23 @@ export const encodeCrossTransferMetadata = (
108
110
  return single ? encodeMultipleActions(data) : data;
109
111
  };
110
112
 
113
+ export const encodeAuthMetadata = (
114
+ params: AuthMetadataProps,
115
+ single = true
116
+ ) => {
117
+ const encodedData = ethers.utils.defaultAbiCoder.encode(
118
+ actionMetadataTypes["auth"],
119
+ [params.address, params.chainId, params.remove]
120
+ );
121
+
122
+ const data = encodeMetadata({
123
+ type: "auth",
124
+ encodedData,
125
+ });
126
+
127
+ return single ? encodeMultipleActions(data) : data;
128
+ };
129
+
111
130
  export const encodeDeployMetadata = (single = true) => {
112
131
  const data = encodeMetadata({
113
132
  type: "deploy",
@@ -223,148 +242,217 @@ export const encodeMultipleActions = (...actionData: string[]) => {
223
242
  return ethers.utils.defaultAbiCoder.encode(multiMetadataTypes, [actionData]);
224
243
  };
225
244
 
226
- export const decodeMetadata = (data: string) => {
245
+ export const decodeData = (data: string) => {
246
+ try {
247
+ const metadata = getMetadataFromData(data) || "0x";
248
+
249
+ return parseMetadata(metadata);
250
+ } catch (e) {
251
+ // console.log(e);
252
+ return null;
253
+ }
254
+ };
255
+
256
+ export const decodeMetadata = (metadata: string) => {
227
257
  try {
228
- const iface = Forwarder__factory.createInterface();
229
- let metadata = "0x";
230
- let payload = {};
231
-
232
- if (!data) return payload;
233
-
234
- if (data.startsWith("0x18e7f485")) {
235
- const executeData = iface.decodeFunctionData("execute", data);
236
- if (executeData.metadata_ === "0x" || !executeData.metadata_) {
237
- return null;
238
- } else {
239
- metadata = executeData.metadata_;
240
- }
258
+ return parseMetadata(metadata);
259
+ } catch (e) {
260
+ return null;
261
+ }
262
+ };
263
+
264
+ const getMetadataFromData = (data: string) => {
265
+ const iface = Forwarder__factory.createInterface();
266
+ let metadata = "0x";
267
+
268
+ if (data.startsWith("0x18e7f485")) {
269
+ const executeData = iface.decodeFunctionData("execute", data);
270
+ if (executeData.metadata_ === "0x" || !executeData.metadata_) {
271
+ return null;
241
272
  } else {
242
- const executeDataV2 = iface.decodeFunctionData("executeV2", data);
243
- if (
244
- executeDataV2.params_.metadata === "0x" ||
245
- !executeDataV2.params_.metadata
246
- ) {
247
- return null;
248
- } else {
249
- metadata = executeDataV2.params_.metadata;
250
- }
273
+ metadata = executeData.metadata_;
251
274
  }
275
+ } else if (data.startsWith("0x14f80a8d")) {
276
+ const executeDataV2 = iface.decodeFunctionData("executeV2", data);
277
+ if (
278
+ executeDataV2.params_.metadata === "0x" ||
279
+ !executeDataV2.params_.metadata
280
+ ) {
281
+ return null;
282
+ } else {
283
+ metadata = executeDataV2.params_.metadata;
284
+ }
285
+ } else if (data.startsWith("0x85114d53")) {
286
+ const executeDataV3 = iface.decodeFunctionData("executeV3", data);
287
+ if (
288
+ executeDataV3.params_.metadata === "0x" ||
289
+ !executeDataV3.params_.metadata
290
+ ) {
291
+ return null;
292
+ } else {
293
+ metadata = executeDataV3.params_.metadata;
294
+ }
295
+ } else {
296
+ const executeDataMultisigV3 = iface.decodeFunctionData(
297
+ "executeMultisigV3",
298
+ data
299
+ );
300
+ if (
301
+ executeDataMultisigV3.params_.metadata === "0x" ||
302
+ !executeDataMultisigV3.params_.metadata
303
+ ) {
304
+ return null;
305
+ } else {
306
+ metadata = executeDataMultisigV3.params_.metadata;
307
+ }
308
+ }
252
309
 
253
- const metadataArr = [];
254
-
255
- const [decodedMultiMetadata = []] =
256
- (ethers.utils.defaultAbiCoder.decode(
257
- multiMetadataTypes,
258
- metadata
259
- ) as string[]) || [];
260
-
261
- for (let metadata of decodedMultiMetadata) {
262
- const decodedMetadata = ethers.utils.defaultAbiCoder.decode(
263
- metadataTypes,
264
- metadata
265
- );
266
-
267
- const type = ethers.utils.parseBytes32String(
268
- decodedMetadata.type
269
- ) as keyof typeof actionMetadataTypes;
270
-
271
- const decodedData = ethers.utils.defaultAbiCoder.decode(
272
- actionMetadataTypes[type],
273
- decodedMetadata.data
274
- );
275
-
276
- switch (type) {
277
- case "transfer":
278
- payload = {
279
- type,
280
- token: decodedData.token,
281
- amount: toBN(decodedData.amount).toFixed(),
282
- receiver: decodedData.receiver,
283
- };
284
- break;
285
- case "bridge":
286
- payload = {
287
- type,
288
- amount: toBN(decodedData.amount).toFixed(),
289
- receiver: decodedData.receiver,
290
- toToken: decodedData.toToken,
291
- fromToken: decodedData.fromToken,
292
- toChainId: decodedData.toChainId
293
- ? decodedData.toChainId.toString()
294
- : null,
295
- bridgeFee: toBN(decodedData.bridgeFee).toFixed(),
296
- };
297
- break;
298
- case "swap":
299
- payload = {
300
- type,
301
- buyAmount: toBN(decodedData.buyAmount).toFixed(),
302
- sellAmount: toBN(decodedData.sellAmount).toFixed(),
303
- buyToken: decodedData.buyToken,
304
- sellToken: decodedData.sellToken,
305
- receiver: decodedData.receiver,
306
- protocol: utils.parseBytes32String(decodedData?.protocol || ""),
307
- };
308
- break;
309
- case "upgrade":
310
- payload = {
311
- type,
312
- version: utils.parseBytes32String(decodedData?.version || ""),
313
- walletImpl: decodedData?.walletImpl,
314
- };
315
- break;
316
- case "gas-topup":
317
- payload = {
318
- type,
319
- amount: toBN(decodedData.amount).toFixed(),
320
- token: decodedData.token,
321
- onBehalf: decodedData.onBehalf,
322
- };
323
- break;
324
- case "dapp":
325
- payload = {
326
- type,
327
- name: decodedData?.name,
328
- url: decodedData?.url,
329
- };
330
- break;
331
- case "deploy":
332
- payload = {
333
- type,
334
- };
335
- break;
336
-
337
- case "permit2":
338
- payload = {
339
- type,
340
- token: decodedData.token,
341
- spender: decodedData.spender,
342
- amount: toBN(decodedData.amount).toFixed(),
343
- expiration: decodedData.expiration,
344
- };
345
- break;
346
-
347
- case "cross-transfer":
348
- payload = {
349
- type,
350
- fromToken: decodedData.fromToken,
351
- toToken: decodedData.toToken,
352
- toChainId: decodedData.toChainId
353
- ? decodedData.toChainId.toString()
354
- : null,
355
- amount: toBN(decodedData.amount).toFixed(),
356
- receiver: decodedData.receiver,
357
- };
358
-
359
- break;
360
- }
361
-
362
- metadataArr.push(payload);
310
+ return metadata;
311
+ };
312
+
313
+ const parseMetadata = (metadata: string) => {
314
+ const metadataArr = [];
315
+ let payload = {};
316
+
317
+ const [decodedMultiMetadata = []] =
318
+ (ethers.utils.defaultAbiCoder.decode(
319
+ multiMetadataTypes,
320
+ metadata
321
+ ) as string[]) || [];
322
+
323
+ for (let metadata of decodedMultiMetadata) {
324
+ const decodedMetadata = ethers.utils.defaultAbiCoder.decode(
325
+ metadataTypes,
326
+ metadata
327
+ );
328
+
329
+ const type = ethers.utils.parseBytes32String(
330
+ decodedMetadata.type
331
+ ) as keyof typeof actionMetadataTypes;
332
+
333
+ const decodedData = ethers.utils.defaultAbiCoder.decode(
334
+ actionMetadataTypes[type],
335
+ decodedMetadata.data
336
+ );
337
+
338
+ switch (type) {
339
+ case "transfer":
340
+ payload = {
341
+ type,
342
+ token: decodedData.token,
343
+ amount: toBN(decodedData.amount).toFixed(),
344
+ receiver: decodedData.receiver,
345
+ };
346
+ break;
347
+ case "bridge":
348
+ payload = {
349
+ type,
350
+ amount: toBN(decodedData.amount).toFixed(),
351
+ receiver: decodedData.receiver,
352
+ toToken: decodedData.toToken,
353
+ fromToken: decodedData.fromToken,
354
+ toChainId: decodedData.toChainId
355
+ ? decodedData.toChainId.toString()
356
+ : null,
357
+ bridgeFee: toBN(decodedData.bridgeFee).toFixed(),
358
+ };
359
+ break;
360
+ case "swap":
361
+ payload = {
362
+ type,
363
+ buyAmount: toBN(decodedData.buyAmount).toFixed(),
364
+ sellAmount: toBN(decodedData.sellAmount).toFixed(),
365
+ buyToken: decodedData.buyToken,
366
+ sellToken: decodedData.sellToken,
367
+ receiver: decodedData.receiver,
368
+ protocol: utils.parseBytes32String(decodedData?.protocol || ""),
369
+ };
370
+ break;
371
+ case "upgrade":
372
+ payload = {
373
+ type,
374
+ version: utils.parseBytes32String(decodedData?.version || ""),
375
+ walletImpl: decodedData?.walletImpl,
376
+ };
377
+ break;
378
+ case "gas-topup":
379
+ payload = {
380
+ type,
381
+ amount: toBN(decodedData.amount).toFixed(),
382
+ token: decodedData.token,
383
+ onBehalf: decodedData.onBehalf,
384
+ };
385
+ break;
386
+ case "dapp":
387
+ payload = {
388
+ type,
389
+ name: decodedData?.name,
390
+ url: decodedData?.url,
391
+ };
392
+ break;
393
+ case "deploy":
394
+ payload = {
395
+ type,
396
+ };
397
+ break;
398
+
399
+ case "permit2":
400
+ payload = {
401
+ type,
402
+ token: decodedData.token,
403
+ spender: decodedData.spender,
404
+ amount: toBN(decodedData.amount).toFixed(),
405
+ expiration: decodedData.expiration,
406
+ };
407
+ break;
408
+
409
+ case "cross-transfer":
410
+ payload = {
411
+ type,
412
+ fromToken: decodedData.fromToken,
413
+ toToken: decodedData.toToken,
414
+ toChainId: decodedData.toChainId
415
+ ? decodedData.toChainId.toString()
416
+ : null,
417
+ amount: toBN(decodedData.amount).toFixed(),
418
+ receiver: decodedData.receiver,
419
+ };
420
+
421
+ break;
422
+ case "auth":
423
+ payload = {
424
+ type: decodedData.remove ? "remove-authority" : "add-authority",
425
+ address: decodedData.address,
426
+ chainId: decodedData.chainId ? decodedData.chainId.toString() : null,
427
+ remove: decodedData.remove,
428
+ };
429
+
430
+ break;
431
+ case "instadapp-pro":
432
+ payload = {
433
+ type,
434
+ castDetails: decodedData.castDetails,
435
+ };
436
+
437
+ break;
363
438
  }
364
439
 
365
- return metadataArr;
366
- } catch (e) {
367
- console.log(e);
368
- return null;
440
+ metadataArr.push(payload);
369
441
  }
442
+
443
+ return metadataArr;
444
+ };
445
+
446
+ /**
447
+ * Replaces hyphens with spaces and capitalizes the first letter of each word in a sentence.
448
+ * @param {string} txType - The input sentence to modify
449
+ *
450
+ * @returns {string} - The modified sentence with hyphens replaced with spaces and the first letter of each word capitalized.
451
+ */
452
+ export const formatTxType = (txType: string) => {
453
+ const finalSentence = txType
454
+ .replace("-", " ")
455
+ .replace(/(^\w{1})|(\s+\w{1})/g, (letter) => letter.toUpperCase());
456
+
457
+ return finalSentence;
370
458
  };
package/utils/network.ts CHANGED
@@ -4,7 +4,7 @@ export const bridgeDisabledNetworks = [1101];
4
4
 
5
5
  export const networks: Network[] = [
6
6
  {
7
- name: "Mainnet",
7
+ name: "Ethereum",
8
8
  debankName: "eth",
9
9
  ankrName: "eth",
10
10
  zerionName: "ethereum",
@@ -114,7 +114,7 @@ export const networks: Network[] = [
114
114
  symbol: "AVAX",
115
115
  decimals: 18,
116
116
  },
117
- rpcUrls: ["https://api.avax.network/ext/bc/C/rpc"],
117
+ rpcUrls: ["https://rpc.ankr.com/avalanche"],
118
118
  },
119
119
  },
120
120
  {
@@ -174,7 +174,7 @@ export const networks: Network[] = [
174
174
  },
175
175
  params: {
176
176
  chainName: "polygon zkEVM",
177
- rpcUrls: ["https://rpc.ankr.com/polygon_zkevm"],
177
+ rpcUrls: ["https://zkevm-rpc.com"],
178
178
 
179
179
  nativeCurrency: {
180
180
  name: "Ethereum",
@@ -183,26 +183,27 @@ export const networks: Network[] = [
183
183
  },
184
184
  },
185
185
  },
186
- // {
187
- // name: "Aurora",
188
- // chainId: 1313161554,
189
- // zerionName: "aurora",
190
- // explorerUrl: "https://explorer.mainnet.aurora.dev",
191
- // get serverRpcUrl() {
192
- // return process.env?.AURORA_RPC_URL || this.params.rpcUrls[0];
193
- // },
194
- // usdcAddress: "0xB12BFcA5A55806AaF64E99521918A4bf0fC40802",
195
- // balanceResolverAddress: "0xdF19Da523DA64bBE82eE0E4DFf00d676A8386474",
196
- // params: {
197
- // rpcUrls: ["https://mainnet.aurora.dev"],
198
- // chainName: "Aurora",
199
- // nativeCurrency: {
200
- // decimals: 18,
201
- // name: "Aurora ETH",
202
- // symbol: "AETH",
203
- // },
204
- // },
205
- // },
186
+ {
187
+ name: "Aurora",
188
+ chainId: 1313161554,
189
+ zerionName: "aurora",
190
+ color: "#78d64b",
191
+ explorerUrl: "https://explorer.mainnet.aurora.dev",
192
+ get serverRpcUrl() {
193
+ return process.env?.AURORA_RPC_URL || this.params.rpcUrls[0];
194
+ },
195
+ usdcAddress: "0xB12BFcA5A55806AaF64E99521918A4bf0fC40802",
196
+ balanceResolverAddress: "0xdF19Da523DA64bBE82eE0E4DFf00d676A8386474",
197
+ params: {
198
+ rpcUrls: ["https://mainnet.aurora.dev"],
199
+ chainName: "Aurora",
200
+ nativeCurrency: {
201
+ decimals: 18,
202
+ name: "Aurora ETH",
203
+ symbol: "AETH",
204
+ },
205
+ },
206
+ },
206
207
  {
207
208
  name: "Fantom",
208
209
  chainId: 250,
@@ -0,0 +1,14 @@
1
+ export const fetchTokenByAddress = async (
2
+ address: string,
3
+ chainId: string | number
4
+ ) => {
5
+ if (!address || !chainId) return null;
6
+ const [token] = (await $fetch(`${blockQueryURL}/${chainId}/tokens`, {
7
+ params: {
8
+ sparkline: false,
9
+ "addresses[]": [address],
10
+ },
11
+ })) as ITokenPrice[];
12
+
13
+ return token;
14
+ };
package/utils/utils.d.ts CHANGED
@@ -64,6 +64,12 @@ type CrossSendMetadataProps = {
64
64
  receiver: string;
65
65
  };
66
66
 
67
+ type AuthMetadataProps = {
68
+ address: string;
69
+ chainId: string;
70
+ remove: boolean;
71
+ };
72
+
67
73
  type UpgradeMetadataProps = {
68
74
  version: string;
69
75
  walletImpl: string;
@@ -105,7 +111,20 @@ type MetadataProps = {
105
111
  | "dapp"
106
112
  | "deploy"
107
113
  | "permit2"
108
- | "cross-transfer";
114
+ | "cross-transfer"
115
+ | "auth";
109
116
  encodedData: string;
110
117
  version?: string;
111
118
  };
119
+
120
+ interface ITokenPrice {
121
+ address: string;
122
+ chain_id: string;
123
+ name: string;
124
+ symbol: string;
125
+ decimals: number;
126
+ logo_url: string;
127
+ price: string;
128
+ coingecko_id: string;
129
+ sparkline_price_7d: number[];
130
+ }