umfangreiche Behebung von TS-Fehlern. "npm run types" läuft nun ohne Fehler durch
This commit is contained in:
@@ -704,7 +704,7 @@ function PendingPhotosCard({
|
||||
return (
|
||||
<div key={photo.id} className="relative">
|
||||
<img
|
||||
src={photo.thumbnail_url ?? photo.url}
|
||||
src={photo.thumbnail_url ?? photo.url ?? undefined}
|
||||
alt={photo.caption ?? 'Foto'}
|
||||
className={`h-24 w-full rounded-lg object-cover ${hidden ? 'opacity-60' : ''}`}
|
||||
/>
|
||||
@@ -779,7 +779,7 @@ function RecentUploadsCard({ slug, photos }: { slug: string; photos: TenantPhoto
|
||||
return (
|
||||
<div key={photo.id} className="relative">
|
||||
<img
|
||||
src={photo.thumbnail_url ?? photo.url}
|
||||
src={photo.thumbnail_url ?? photo.url ?? undefined}
|
||||
alt={photo.caption ?? 'Foto'}
|
||||
className={`h-24 w-full rounded-lg object-cover ${hidden ? 'opacity-60' : ''}`}
|
||||
/>
|
||||
@@ -811,7 +811,7 @@ function FeedbackCard({ slug }: { slug: string }) {
|
||||
const [message, setMessage] = React.useState('');
|
||||
const [busy, setBusy] = React.useState(false);
|
||||
const [submitted, setSubmitted] = React.useState(false);
|
||||
const [error, setError] = React.useState<string | null>(null);
|
||||
const [error, setError] = React.useState<string | undefined>(undefined);
|
||||
|
||||
const copy = {
|
||||
positive: t('events.feedback.positive', 'Super Lauf!'),
|
||||
@@ -862,7 +862,7 @@ function FeedbackCard({ slug }: { slug: string }) {
|
||||
onClick={async () => {
|
||||
if (busy || submitted) return;
|
||||
setBusy(true);
|
||||
setError(null);
|
||||
setError(undefined);
|
||||
|
||||
try {
|
||||
await submitTenantFeedback({
|
||||
|
||||
Reference in New Issue
Block a user