fix(tui): normalize attachment labels

This commit is contained in:
Dax Raad 2026-07-06 19:22:25 -04:00
commit 7668eb728d

View file

@ -1448,10 +1448,10 @@ function UserMessage(props: { message: SessionMessageUser }) {
>
<For each={files()}>
{(file) => {
const label = file.mime === "application/x-directory" ? "Directory" : file.mime
const label = file.mime === "application/x-directory" ? "dir" : "file"
return (
<text fg={theme.text}>
<span style={{ bg: theme.secondary, fg: theme.background }}>{` ${label} `}</span>
<span style={{ bg: theme.secondary, fg: theme.background, bold: true }}>{` ${label} `}</span>
<span style={{ bg: theme.backgroundElement, fg: theme.textMuted }}>
{" "}
{file.name ?? (file.source.type === "uri" ? file.source.uri : "attachment")}{" "}