Skip to content

Commit

Permalink
feat: remove definitions
Browse files Browse the repository at this point in the history
  • Loading branch information
0xkenj1 committed Aug 16, 2024
1 parent 1d3ace4 commit 22a70cd
Showing 1 changed file with 5 additions and 15 deletions.
20 changes: 5 additions & 15 deletions apps/api/src/metrics/dto/response/chain.dto.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { ApiProperty, ApiPropertyOptional } from "@nestjs/swagger";
import { ApiPropertyOptional } from "@nestjs/swagger";

import { AssetTvl } from "@zkchainhub/metrics/types";
import { Chains, ChainType, Token } from "@zkchainhub/shared";
import { ChainType, Token } from "@zkchainhub/shared";

import { BatchesInfo, FeeParams, L2ChainInfo, ZkChainMetadata } from ".";

Expand All @@ -14,36 +14,26 @@ export class ZKChainInfo {
* @type {ChainType}
* @memberof ZKChainInfo
*/
@ApiProperty({ enum: Chains, enumName: "ChainType" })
chainType: ChainType;

/**
* The native token of the chain (optional).
* @type {string}
* @type {Token<"erc20" | "native">}
* @memberof ZKChainSummary
*/
baseToken?: Token<"erc20" | "native">;
/**
* A map of asset names to their respective amounts.
* @type {AssetDistribution}
* @type {AssetTvl}
* @memberof ZKChainInfo
* @example { ETH: 1000000, ZK: 500000 }
*/
@ApiProperty({
example: { ETH: 1000000, ZK: 500000 },
description: "A map of asset names to their respective amounts",
additionalProperties: {
type: "number",
},
})
tvl: AssetTvl[];

/**
* Optional batches information.
* @type {BatchesInfo}
* @memberof ZKChainInfo
*/
@ApiPropertyOptional()
batchesInfo?: BatchesInfo;

/**
Expand All @@ -55,7 +45,7 @@ export class ZKChainInfo {

/**
* Optional metadata.
* @type {Metadata}
* @type {ZkChainMetadata}
* @memberof ZKChainInfo
*/
@ApiPropertyOptional({ type: ZkChainMetadata })
Expand Down

0 comments on commit 22a70cd

Please sign in to comment.