@@ -16,8 +16,8 @@ import {
1616} from "lucide-react" ;
1717import { useCallback , useEffect , useMemo } from "react" ;
1818import { DataTable } from "@/components/analytics/data-table" ;
19- import { BrowserIcon , OSIcon } from "@/components/icon" ;
20- import { Card , CardContent , CardDescription , CardHeader , CardTitle } from "@/components/ui/card" ;
19+ import { BrowserIcon } from "@/components/icon" ;
20+ import { Card , CardContent , CardHeader } from "@/components/ui/card" ;
2121import { Skeleton } from "@/components/ui/skeleton" ;
2222import { useBatchDynamicQuery } from "@/hooks/use-dynamic-query" ;
2323import { PercentageBadge , type TechnologyTableEntry } from "../utils/technology-helpers" ;
@@ -97,7 +97,7 @@ interface ProcessedData {
9797}
9898
9999const formatNumber = ( value : number | null | undefined ) : string => {
100- if ( value == null || isNaN ( value ) ) return "0" ;
100+ if ( value == null || Number . isNaN ( value ) ) return "0" ;
101101 return Intl . NumberFormat ( undefined , { notation : "compact" , maximumFractionDigits : 1 } ) . format ( value ) ;
102102} ;
103103
@@ -126,21 +126,6 @@ const normalizeData = (data: any[]): GeographicEntry[] =>
126126 country_name : item . country_name ,
127127 } ) ) || [ ] ;
128128
129- const createNameColumn = ( header : string , renderIcon ?: ( name : string ) => React . ReactNode ) => ( {
130- id : "name" ,
131- accessorKey : "name" ,
132- header,
133- cell : ( info : CellContext < any , any > ) => {
134- const name = info . getValue ( ) as string ;
135- return (
136- < div className = "flex items-center gap-2" >
137- { renderIcon ?.( name ) }
138- < span className = "font-medium" > { name } </ span >
139- </ div >
140- ) ;
141- } ,
142- } ) ;
143-
144129export function WebsiteAudienceTab ( {
145130 websiteId,
146131 dateRange,
@@ -784,7 +769,7 @@ export function WebsiteAudienceTab({
784769 getSubRows = { ( row : any ) => row . versions }
785770 isLoading = { isLoading }
786771 minHeight = { 350 }
787- renderSubRow = { ( subRow : any , parentRow : any , index : number ) => {
772+ renderSubRow = { ( subRow : any , parentRow : any ) => {
788773 const percentage = Math . round (
789774 ( ( subRow . visitors || 0 ) / ( parentRow . visitors || 1 ) ) * 100
790775 ) ;
0 commit comments