Skip to content

Commit

Permalink
add missing columns
Browse files Browse the repository at this point in the history
  • Loading branch information
nguyenlejoe committed Jan 11, 2024
1 parent a2c2e21 commit 33219ef
Showing 1 changed file with 45 additions and 4 deletions.
49 changes: 45 additions & 4 deletions src/components/Organisms/XYK/XYKPoolListView/XYKPoolListView.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ export const XYKPoolListView: React.FC<XYKPoolListViewProps> = ({

const [sorting, setSorting] = useState<SortingState>([
{
id: "quote_rate",
id: "total_liquidity_quote",
desc: true,
},
]);
Expand Down Expand Up @@ -125,7 +125,7 @@ export const XYKPoolListView: React.FC<XYKPoolListViewProps> = ({
cell: ({ row }) => {
const token_0 = row.original.token_0;
const token_1 = row.original.token_1;
const pool = `${token_0.contract_ticker_symbol}/${token_1.contract_ticker_symbol}`;
const pool = `${token_0.contract_ticker_symbol}-${token_1.contract_ticker_symbol}`;

return (
<div className="flex items-center gap-3">
Expand Down Expand Up @@ -170,8 +170,8 @@ export const XYKPoolListView: React.FC<XYKPoolListViewProps> = ({
},
},
{
id: "total_volume_24h_quote",
accessorKey: "total_volume_24h_quote",
id: "volume_24h_quote",
accessorKey: "volume_24h_quote",
header: ({ column }) => (
<TableHeaderSorting
align="right"
Expand All @@ -187,6 +187,24 @@ export const XYKPoolListView: React.FC<XYKPoolListViewProps> = ({
return <div className="text-right">{valueFormatted}</div>;
},
},
{
id: "volume_7d_quote",
accessorKey: "volume_7d_quote",
header: ({ column }) => (
<TableHeaderSorting
align="right"
header_name={"Volume (7d)"}
column={column}
/>
),
cell: ({ row }) => {
const valueFormatted = prettifyCurrency(
row.original.volume_7d_quote
);

return <div className="text-right">{valueFormatted}</div>;
},
},
{
id: "quote_rate",
accessorKey: "quote_rate",
Expand All @@ -211,6 +229,24 @@ export const XYKPoolListView: React.FC<XYKPoolListViewProps> = ({
);
},
},
{
id: "fee_24h_quote",
accessorKey: "fee_24h_quote",
header: ({ column }) => (
<TableHeaderSorting
align="right"
header_name={"Fees (24hrs)"}
column={column}
/>
),
cell: ({ row }) => {
const valueFormatted = prettifyCurrency(
row.original.fee_24h_quote
);

return <div className="text-right">{valueFormatted}</div>;
},
},
{
id: "actions",
cell: ({ row }) => {
Expand Down Expand Up @@ -429,6 +465,11 @@ export const XYKPoolListView: React.FC<XYKPoolListViewProps> = ({
<Skeleton size={GRK_SIZES.LARGE} />
</div>
</TableCell>
<TableCell className="h-12 text-right">
<div className="float-right">
<Skeleton size={GRK_SIZES.LARGE} />
</div>
</TableCell>
</TableRow>
),
Some: () =>
Expand Down

0 comments on commit 33219ef

Please sign in to comment.