From bf14357285a26afdedf8964e588d24e892459d36 Mon Sep 17 00:00:00 2001 From: Tiago Yamamoto Date: Mon, 16 Feb 2026 09:05:48 -0600 Subject: [PATCH] fix: align Notification interface between api.ts and types.ts - Add 'read' field to Notification interface in api.ts - Remove duplicate Notification interface in candidate-dashboard.tsx - Import Notification type from api.ts to ensure consistency --- .../dashboard-contents/candidate-dashboard.tsx | 11 +---------- frontend/src/lib/api.ts | 2 +- 2 files changed, 2 insertions(+), 11 deletions(-) diff --git a/frontend/src/components/dashboard-contents/candidate-dashboard.tsx b/frontend/src/components/dashboard-contents/candidate-dashboard.tsx index f2bd2e5..b7628c3 100644 --- a/frontend/src/components/dashboard-contents/candidate-dashboard.tsx +++ b/frontend/src/components/dashboard-contents/candidate-dashboard.tsx @@ -14,7 +14,7 @@ import { TableRow, } from "@/components/ui/table" import { mockNotifications } from "@/lib/mock-data" -import { jobsApi, applicationsApi, transformApiJobToFrontend, notificationsApi } from "@/lib/api" +import { jobsApi, applicationsApi, transformApiJobToFrontend, notificationsApi, Notification } from "@/lib/api" import { Job, ApplicationWithDetails } from "@/lib/types" import { Bell, @@ -30,15 +30,6 @@ import { getCurrentUser } from "@/lib/auth" import { useTranslation } from "@/lib/i18n" import { useState, useEffect } from "react" -interface Notification { - id: string; - title: string; - message: string; - type: string; - read: boolean; - createdAt: string; -} - export function CandidateDashboardContent() { const { t } = useTranslation() const user = getCurrentUser() diff --git a/frontend/src/lib/api.ts b/frontend/src/lib/api.ts index f79b800..3e23405 100644 --- a/frontend/src/lib/api.ts +++ b/frontend/src/lib/api.ts @@ -613,7 +613,7 @@ export interface Notification { title: string; message: string; link?: string; - readAt?: string; + read: boolean; createdAt: string; }