fix: address code review — responsive overflow, map minWidth, DataTable mobile click handler

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
fuomag9
2026-03-12 09:58:45 +01:00
parent 27b7fadacc
commit cf7eb7757e
4 changed files with 5 additions and 5 deletions

View File

@@ -230,7 +230,7 @@ export default function DashboardLayoutClient({ user, children }: { user: User;
p: { xs: 2, md: 5 },
width: { md: `calc(100% - ${DRAWER_WIDTH}px)` },
mt: { xs: `${APP_BAR_HEIGHT}px`, md: 0 },
overflowX: 'hidden',
overflowX: { xs: 'hidden', md: 'visible' },
}}
>
<Box sx={{ maxWidth: 1200, mx: "auto" }}>

View File

@@ -591,8 +591,8 @@ export default function AnalyticsClient() {
) : (
<>
<Box sx={{ overflowX: "auto", width: "100%" }}>
<ReactApexChart type="donut" series={donutSeries} options={donutOptions} height={220} />
</Box>
<ReactApexChart type="donut" series={donutSeries} options={donutOptions} height={220} />
</Box>
<Table size="small" sx={{ mt: 1 }}>
<TableBody>
{protocols.map(p => (

View File

@@ -289,7 +289,7 @@ export default function WorldMapInner({ data, selectedCountry }: { data: Country
border: '1px solid rgba(148,163,184,0.08)',
flex: 1,
minHeight: 280,
minWidth: { xs: 0, sm: 400 },
minWidth: 400,
width: '100%',
}}>
<MapGL

View File

@@ -94,7 +94,7 @@ export function DataTable<T>({
) : (
<Stack spacing={1.5}>
{data.map((row) => (
<Box key={String(row[keyField])} onClick={onRowClick ? () => onRowClick(row) : undefined} sx={onRowClick ? { cursor: "pointer" } : undefined}>
<Box key={String(row[keyField])}>
{mobileCard(row)}
</Box>
))}