fix: resolve build errors for Vercel deployment
TypeScript and ESLint fixes: - Fixed unescaped quotes in report-timeline.tsx (ESLint error) - Restored database.types.ts from git history (was empty) - Added reports table type definition to database.types.ts - Fixed missing getCookieHeader import in intakes/actions.ts - Fixed use-media-query.ts ternary operator (TypeScript error) - Simplified z.enum() in report.ts (removed unsupported error options) All type checking and linting now passes successfully. Build tested locally and ready for Vercel deployment. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -9,7 +9,7 @@
|
|||||||
|
|
||||||
import { revalidatePath } from 'next/cache';
|
import { revalidatePath } from 'next/cache';
|
||||||
import { redirect } from 'next/navigation';
|
import { redirect } from 'next/navigation';
|
||||||
import { authFetch, getBaseUrl } from '@/lib/server/api-client';
|
import { authFetch, getBaseUrl, getCookieHeader } from '@/lib/server/api-client';
|
||||||
import type {
|
import type {
|
||||||
Intake,
|
Intake,
|
||||||
CreateIntakeInput,
|
CreateIntakeInput,
|
||||||
|
|||||||
@@ -63,7 +63,7 @@ export function ReportTimeline({
|
|||||||
</div>
|
</div>
|
||||||
<p className="text-base font-semibold text-slate-900">Nog geen rapportages</p>
|
<p className="text-base font-semibold text-slate-900">Nog geen rapportages</p>
|
||||||
<p className="mt-1 text-sm text-slate-500">
|
<p className="mt-1 text-sm text-slate-500">
|
||||||
Klik op "Nieuwe rapportage" in de header om de eerste rapportage vast te leggen.
|
Klik op “Nieuwe rapportage” in de header om de eerste rapportage vast te leggen.
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -9,7 +9,7 @@ export function useMediaQuery(query: string) {
|
|||||||
if (typeof window === 'undefined') return;
|
if (typeof window === 'undefined') return;
|
||||||
const mediaQuery = window.matchMedia(query);
|
const mediaQuery = window.matchMedia(query);
|
||||||
const handleChange = (event: MediaQueryListEvent | MediaQueryList) => {
|
const handleChange = (event: MediaQueryListEvent | MediaQueryList) => {
|
||||||
setMatches('matches' in event ? event.matches : event.matches);
|
setMatches(event.matches);
|
||||||
};
|
};
|
||||||
|
|
||||||
setMatches(mediaQuery.matches);
|
setMatches(mediaQuery.matches);
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
@@ -10,9 +10,7 @@ export type ReportType = (typeof REPORT_TYPES)[number];
|
|||||||
|
|
||||||
export const CreateReportSchema = z.object({
|
export const CreateReportSchema = z.object({
|
||||||
patient_id: z.string().uuid('Patient ID moet een geldige UUID zijn'),
|
patient_id: z.string().uuid('Patient ID moet een geldige UUID zijn'),
|
||||||
type: z.enum(REPORT_TYPES, {
|
type: z.enum(REPORT_TYPES),
|
||||||
errorMap: () => ({ message: 'Type moet behandeladvies of vrije_notitie zijn' }),
|
|
||||||
}),
|
|
||||||
content: z
|
content: z
|
||||||
.string()
|
.string()
|
||||||
.min(20, 'Rapportage moet minimaal 20 karakters bevatten')
|
.min(20, 'Rapportage moet minimaal 20 karakters bevatten')
|
||||||
|
|||||||
Reference in New Issue
Block a user