@@ -106,7 +106,7 @@ export const DataTable = memo(<TData extends UserResponse, TValue>({ columns, da
106106
107107 return (
108108 < div className = "overflow-hidden rounded-md border" >
109- < Table dir = { isRTL ? 'rtl' : 'ltr' } className = "table-fixed md:table-auto" >
109+ < Table dir = { isRTL ? 'rtl' : 'ltr' } >
110110 < TableHeader >
111111 { table . getHeaderGroups ( ) . map ( headerGroup => (
112112 < TableRow key = { headerGroup . id } className = "uppercase" >
@@ -116,11 +116,11 @@ export const DataTable = memo(<TData extends UserResponse, TValue>({ columns, da
116116 className = { cn (
117117 'sticky z-10 bg-background text-xs' ,
118118 isRTL && 'text-right' ,
119- index === 0 && 'min-w-0 max- w-[40% ] md:w-auto' ,
120- index === 1 && 'w-[70px] min -w-[70px] !px-0 md:w-auto' ,
121- index === 2 && 'min-w-0 flex-1 px-1 md:w-[450px]' ,
119+ index === 0 && 'w-[200px] sm: w-[270px ] md:w-auto' ,
120+ index === 1 && 'max -w-[70px] !px-0 md:w-auto' ,
121+ index === 2 && 'min-w-[100px] px-1 md:w-[450px]' ,
122122 index >= 3 && 'hidden md:table-cell' ,
123- header . id === 'chevron' && 'table-cell w-10 flex-shrink-0 md:hidden' ,
123+ header . id === 'chevron' && 'table-cell md:hidden' ,
124124 ) }
125125 >
126126 { header . isPlaceholder ? null : flexRender ( header . column . columnDef . header , header . getContext ( ) ) }
@@ -144,14 +144,17 @@ export const DataTable = memo(<TData extends UserResponse, TValue>({ columns, da
144144 < TableCell
145145 key = { cell . id }
146146 className = { cn (
147- 'whitespace-nowrap py-2 text-sm' ,
148- index <= 1 && 'max-w-[calc(100vw-50px-32px-100px-48px)] md:py-2' ,
149- index === 2 && 'w-[120px] !p-0 px-1' ,
147+ 'text-sm' ,
148+ index !== 2 && 'whitespace-nowrap' ,
149+ index === 2 && 'md:whitespace-nowrap' ,
150+ index !== 2 && 'py-1.5' ,
151+ index <= 1 && 'max-w-[calc(100vw-50px-32px-100px-60px)] md:py-2' ,
152+ index === 2 && 'min-w-[100px] max-w-full md:w-[450px]' ,
150153 index === 3 && 'w-8' ,
151- index === 3 && isRTL ? '!pr-0' : index === 3 && ! isRTL && '!pl-0' ,
154+ index === 3 && "!p-0" ,
152155 index >= 4 && 'hidden !p-0 md:table-cell' ,
153156 cell . column . id === 'chevron' && 'table-cell md:hidden' ,
154- isRTL ? 'pl-1.5 sm:pl-3' : 'pr-1.5 sm:pr-3' ,
157+ index !== 2 && ( isRTL ? 'pl-1.5 sm:pl-3' : 'pr-1.5 sm:pr-3' ) ,
155158 ) }
156159 >
157160 { cell . column . id === 'chevron' ? (
@@ -184,4 +187,4 @@ export const DataTable = memo(<TData extends UserResponse, TValue>({ columns, da
184187 </ Table >
185188 </ div >
186189 )
187- } )
190+ } )
0 commit comments