@@ -5,13 +5,14 @@ import { formatTimeSince } from "~/lib/utils";
5
5
import { routes } from "~/routes/__root" ;
6
6
import type { BlockTableSchema } from "./blocks-schema" ;
7
7
import { truncateHashString } from "~/lib/create-hash-string" ;
8
+ import { BlockStatusBadge } from "../block-status-badge" ;
8
9
9
10
const text = {
10
11
height : "HEIGHT" ,
11
12
blockHash : "BLOCK HASH" ,
12
13
txEffectsLength : "NBR OF TXS" ,
13
- totalFees : "FEES (FPA)" ,
14
14
timeSince : "AGE" ,
15
+ blockStatus : "BLOCK STATUS"
15
16
} ;
16
17
17
18
export const BlockTableColumns : ColumnDef < BlockTableSchema > [ ] = [
@@ -48,7 +49,7 @@ export const BlockTableColumns: ColumnDef<BlockTableSchema>[] = [
48
49
) ,
49
50
cell : ( { row } ) => {
50
51
const blockHash = row . getValue ( "blockHash" ) ;
51
- if ( typeof blockHash !== "string" ) return null ;
52
+ if ( typeof blockHash !== "string" ) { return null ; }
52
53
const r = `${ routes . blocks . route } /${ blockHash } ` ;
53
54
return (
54
55
< div className = "text-purple-light font-mono" >
@@ -94,18 +95,18 @@ export const BlockTableColumns: ColumnDef<BlockTableSchema>[] = [
94
95
enableHiding : false ,
95
96
} ,
96
97
{
97
- accessorKey : "totalFees " ,
98
+ accessorKey : "blockStatus " ,
98
99
header : ( { column } ) => (
99
100
< DataTableColumnHeader
100
101
className = "text-purple-dark text-sm"
101
102
column = { column }
102
- title = { text . totalFees }
103
+ title = { text . blockStatus }
103
104
/>
104
105
) ,
105
106
cell : ( { row } ) => (
106
- < div className = "font-mono" > { row . getValue ( "totalFees " ) } </ div >
107
+ < BlockStatusBadge className = "font-mono" status = { row . getValue ( "blockStatus " ) } / >
107
108
) ,
108
- enableSorting : true ,
109
+ enableSorting : false ,
109
110
enableHiding : false ,
110
111
} ,
111
112
] ;
0 commit comments