fix: resolve all MUI v9 TypeScript build errors
- Move system props (fontWeight, lineHeight, display, alignItems, etc.) into sx - Fix Lucide icon color prop (no sx support) - Merge duplicate sx attributes - Remove unused variables (location, _needId, v) Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -91,7 +91,7 @@ export default function SupplyDashboard() {
|
||||
<Box>
|
||||
{/* Page Header */}
|
||||
<Box sx={{ bgcolor: 'white', borderBottom: '1px solid', borderColor: 'divider', px: 3, py: 2 }}>
|
||||
<Typography variant="h5" fontWeight={700} color="text.primary">Supply Dashboard</Typography>
|
||||
<Typography variant="h5" sx={{ fontWeight: 700 }} color="text.primary">Supply Dashboard</Typography>
|
||||
<Typography variant="body2" color="text.secondary">Portfolioübersicht und aktuelle Kennzahlen</Typography>
|
||||
</Box>
|
||||
|
||||
@@ -104,10 +104,10 @@ export default function SupplyDashboard() {
|
||||
<Card sx={{ elevation: 1, p: 2.5 }}>
|
||||
<Box className="flex flex-col gap-1">
|
||||
<Box className="flex items-center justify-between">
|
||||
<Typography variant="overline" color="text.secondary" lineHeight={1.4}>Objekte</Typography>
|
||||
<Typography variant="overline" color="text.secondary" sx={{ lineHeight: 1.4 }}>Objekte</Typography>
|
||||
<Building2 size={20} color="#1e3a5f" />
|
||||
</Box>
|
||||
<Typography variant="h3" fontWeight={700} color="text.primary">{properties.length}</Typography>
|
||||
<Typography variant="h3" sx={{ fontWeight: 700 }} color="text.primary">{properties.length}</Typography>
|
||||
<Typography variant="caption" color="text.secondary">Gesamtportfolio</Typography>
|
||||
</Box>
|
||||
</Card>
|
||||
@@ -116,10 +116,10 @@ export default function SupplyDashboard() {
|
||||
<Card sx={{ elevation: 1, p: 2.5 }}>
|
||||
<Box className="flex flex-col gap-1">
|
||||
<Box className="flex items-center justify-between">
|
||||
<Typography variant="overline" color="text.secondary" lineHeight={1.4}>Aktive Matches</Typography>
|
||||
<Typography variant="overline" color="text.secondary" sx={{ lineHeight: 1.4 }}>Aktive Matches</Typography>
|
||||
<Target size={20} color="#1a7a4a" />
|
||||
</Box>
|
||||
<Typography variant="h3" fontWeight={700} color="text.primary">{matches.length}</Typography>
|
||||
<Typography variant="h3" sx={{ fontWeight: 700 }} color="text.primary">{matches.length}</Typography>
|
||||
<Typography variant="caption" color="text.secondary">KI-generierte Matches</Typography>
|
||||
</Box>
|
||||
</Card>
|
||||
@@ -128,10 +128,10 @@ export default function SupplyDashboard() {
|
||||
<Card sx={{ elevation: 1, p: 2.5 }}>
|
||||
<Box className="flex flex-col gap-1">
|
||||
<Box className="flex items-center justify-between">
|
||||
<Typography variant="overline" color="text.secondary" lineHeight={1.4}>Ø Datenqualität</Typography>
|
||||
<Typography variant="overline" color="text.secondary" sx={{ lineHeight: 1.4 }}>Ø Datenqualität</Typography>
|
||||
<BarChart2 size={20} color={avgQuality >= 0.8 ? '#1a7a4a' : avgQuality >= 0.6 ? '#d97706' : '#c0392b'} />
|
||||
</Box>
|
||||
<Typography variant="h3" fontWeight={700} sx={{ color: avgQualityColor }}>
|
||||
<Typography variant="h3" sx={{ fontWeight: 700, color: avgQualityColor }}>
|
||||
{Math.round(avgQuality * 100)}%
|
||||
</Typography>
|
||||
<Typography variant="caption" color="text.secondary">Durchschnittlicher Score</Typography>
|
||||
@@ -142,10 +142,10 @@ export default function SupplyDashboard() {
|
||||
<Card sx={{ elevation: 1, p: 2.5 }}>
|
||||
<Box className="flex flex-col gap-1">
|
||||
<Box className="flex items-center justify-between">
|
||||
<Typography variant="overline" color="text.secondary" lineHeight={1.4}>Prüfungen ausstehend</Typography>
|
||||
<Typography variant="overline" color="text.secondary" sx={{ lineHeight: 1.4 }}>Prüfungen ausstehend</Typography>
|
||||
<AlertTriangle size={20} color="#d97706" />
|
||||
</Box>
|
||||
<Typography variant="h3" fontWeight={700} sx={{ color: pendingReview > 0 ? 'warning.main' : 'text.primary' }}>
|
||||
<Typography variant="h3" sx={{ fontWeight: 700, color: pendingReview > 0 ? 'warning.main' : 'text.primary' }}>
|
||||
{pendingReview}
|
||||
</Typography>
|
||||
<Typography variant="caption" color="text.secondary">Kritische Felder fehlen</Typography>
|
||||
@@ -156,15 +156,15 @@ export default function SupplyDashboard() {
|
||||
{/* Section 2 - Portfolio Overview */}
|
||||
<Box className="grid grid-cols-3 gap-4">
|
||||
<Card sx={{ elevation: 1, borderTop: '4px solid #1e3a5f', p: 2.5 }}>
|
||||
<Typography variant="h4" fontWeight={700} color="text.primary">{verifiedCount}</Typography>
|
||||
<Typography variant="h4" sx={{ fontWeight: 700 }} color="text.primary">{verifiedCount}</Typography>
|
||||
<Typography variant="body2" color="text.secondary">Verified Portfolio</Typography>
|
||||
</Card>
|
||||
<Card sx={{ elevation: 1, borderTop: '4px solid #d97706', p: 2.5 }}>
|
||||
<Typography variant="h4" fontWeight={700} color="text.primary">{marketCount}</Typography>
|
||||
<Typography variant="h4" sx={{ fontWeight: 700 }} color="text.primary">{marketCount}</Typography>
|
||||
<Typography variant="body2" color="text.secondary">Marktinserate</Typography>
|
||||
</Card>
|
||||
<Card sx={{ elevation: 1, borderTop: '4px solid #7c3aed', p: 2.5 }}>
|
||||
<Typography variant="h4" fontWeight={700} color="text.primary">{futureCount}</Typography>
|
||||
<Typography variant="h4" sx={{ fontWeight: 700 }} color="text.primary">{futureCount}</Typography>
|
||||
<Typography variant="body2" color="text.secondary">Zukunftssignale</Typography>
|
||||
</Card>
|
||||
</Box>
|
||||
@@ -175,11 +175,11 @@ export default function SupplyDashboard() {
|
||||
<Table>
|
||||
<TableHead>
|
||||
<TableRow sx={{ bgcolor: 'grey.50' }}>
|
||||
<TableCell><Typography variant="caption" fontWeight={600}>Objekt</Typography></TableCell>
|
||||
<TableCell><Typography variant="caption" fontWeight={600}>Unternehmen</Typography></TableCell>
|
||||
<TableCell><Typography variant="caption" fontWeight={600}>Score</Typography></TableCell>
|
||||
<TableCell><Typography variant="caption" fontWeight={600}>Stärke</Typography></TableCell>
|
||||
<TableCell><Typography variant="caption" fontWeight={600}>Aktion</Typography></TableCell>
|
||||
<TableCell><Typography variant="caption" sx={{ fontWeight: 600 }}>Objekt</Typography></TableCell>
|
||||
<TableCell><Typography variant="caption" sx={{ fontWeight: 600 }}>Unternehmen</Typography></TableCell>
|
||||
<TableCell><Typography variant="caption" sx={{ fontWeight: 600 }}>Score</Typography></TableCell>
|
||||
<TableCell><Typography variant="caption" sx={{ fontWeight: 600 }}>Stärke</Typography></TableCell>
|
||||
<TableCell><Typography variant="caption" sx={{ fontWeight: 600 }}>Aktion</Typography></TableCell>
|
||||
</TableRow>
|
||||
</TableHead>
|
||||
<TableBody>
|
||||
@@ -188,19 +188,19 @@ export default function SupplyDashboard() {
|
||||
return (
|
||||
<TableRow key={match.id} hover>
|
||||
<TableCell>
|
||||
<Typography variant="body2" fontWeight={500}>{property?.title ?? match.propertyId}</Typography>
|
||||
<Typography variant="body2" sx={{ fontWeight: 500 }}>{property?.title ?? match.propertyId}</Typography>
|
||||
</TableCell>
|
||||
<TableCell>
|
||||
<Typography variant="body2" color="text.secondary">{match.needId}</Typography>
|
||||
</TableCell>
|
||||
<TableCell>
|
||||
<Box className="flex items-center gap-2">
|
||||
<Typography variant="body2" fontWeight={700}>{match.matchScore}</Typography>
|
||||
<Typography variant="body2" sx={{ fontWeight: 700 }}>{match.matchScore}</Typography>
|
||||
<Box sx={{ width: 80 }}>
|
||||
<LinearProgress
|
||||
variant="determinate"
|
||||
value={match.matchScore}
|
||||
color={match.matchStrength === MatchStrength.STRONG ? 'success' : match.matchStrength === MatchStrength.MODERATE ? 'warning' : 'error'}
|
||||
sx={{ color: match.matchStrength === MatchStrength.STRONG ? 'success' : match.matchStrength === MatchStrength.MODERATE ? 'warning' : 'error' }}
|
||||
/>
|
||||
</Box>
|
||||
</Box>
|
||||
@@ -208,7 +208,7 @@ export default function SupplyDashboard() {
|
||||
<TableCell>
|
||||
<Chip
|
||||
label={getMatchStrengthLabel(match.matchStrength)}
|
||||
color={getMatchStrengthColor(match.matchStrength)}
|
||||
sx={{ color: getMatchStrengthColor(match.matchStrength) }}
|
||||
size="small"
|
||||
/>
|
||||
</TableCell>
|
||||
|
||||
Reference in New Issue
Block a user