update kanban styling, add more detailed error log for gmail

This commit is contained in:
cesnimda
2026-03-21 19:22:02 +01:00
parent 7211d67c62
commit 793ed6eb65
5 changed files with 210 additions and 134 deletions
@@ -236,8 +236,12 @@ export default function Correspondence({ jobId }: { jobId: number }) {
});
await load();
toast("Email imported from Gmail.", "success");
} catch {
toast("Failed to import Gmail message.", "error");
} catch (error: any) {
const message =
error?.response?.data && typeof error.response.data === "string"
? error.response.data
: "Failed to import Gmail message.";
toast(message, "error");
} finally {
setImportingMessageId(null);
}
@@ -303,8 +307,8 @@ export default function Correspondence({ jobId }: { jobId: number }) {
sx={{ display: "block", mt: 0.75, color: "text.secondary" }}
>
{isMe ? "Me" : "Company"}
{m.channel ? ` · ${m.channel}` : ""}
{m.date ? ` · ${new Date(m.date).toLocaleString()}` : ""}
{m.channel ? ` · ${m.channel}` : ""}
{m.date ? ` · ${new Date(m.date).toLocaleString()}` : ""}
</Typography>
</Box>
</Box>