Open-source Grok Bot alternative with a virtual machine that bots can use
TypeScript ai-agentsclaude-codecodexcomputer-usedockerelectrongrokgrok-botgrok-bot-alternativeself-hostedtypescript
fix(chat): the paged export's two new errors read from the catalogs, with pt-BR
milind-sonif0127c3c7c66
diff --git a/src/lib/conversation-transcript.ts b/src/lib/conversation-transcript.tsindex 5c710f5a44..351841bc81 100644--- a/src/lib/conversation-transcript.ts+++ b/src/lib/conversation-transcript.ts@@ -2,6 +2,7 @@ import { loadFullThread } from "@/state/message-history";import { optimisticMessageId } from "@/state/optimistic-send";import { visibleMessages } from "@/state/snapshot-navigation";import { formatTranscriptMarkdown, type ExportTranscriptOptions } from "./export-transcript";+import { t } from "./i18n";interface ConversationTranscriptOptions extends ExportTranscriptOptions {threadId: string;@@ -37,7 +38,7 @@ export function conversationTranscript({ threadId, hasMore, activeLeafId, ...optconst parent = options.messages[0]?.parentId;if (parent && !aliases.has(parent)) boundary = thread.messages.findIndex((message) => message.id === parent);}- if (boundary < 0) throw new Error("The conversation history at export time is no longer available");+ if (boundary < 0) throw new Error(t("chat.export.historyGone"));// A later confirmation may replace its optimistic row, but cannot extend the history boundary.const confirmedIds = new Set(aliases.values());const history = thread.messages.filter((message, index) => index <= boundary || confirmedIds.has(message.id));@@ -46,7 +47,7 @@ export function conversationTranscript({ threadId, hasMore, activeLeafId, ...opt...[...held.values()].filter((message) => !loaded.has(message.id))];const leaf = activeLeafId ? aliases.get(activeLeafId) ?? activeLeafId : activeLeafId;if (leaf && !messages.some((message) => message.id === leaf)) {- throw new Error("The selected conversation branch is no longer available");+ throw new Error(t("chat.export.branchGone"));}return formatTranscriptMarkdown({ ...options, messages: visibleMessages({ messages, activeLeafId: leaf }) });});diff --git a/src/locales/en.json b/src/locales/en.jsonindex 0337b8472f..773b9d2096 100644--- a/src/locales/en.json+++ b/src/locales/en.json@@ -2796,6 +2796,8 @@"chat.export.download": "Download as .md","chat.export.copyConversation": "Copy conversation","chat.export.downloadConversation": "Download conversation",+ "chat.export.historyGone": "The conversation history at export time is no longer available",+ "chat.export.branchGone": "The selected conversation branch is no longer available","chat.usage.menu": "Usage","chat.conversationWith": "Conversation with {name}","chat.showEarlier": "Show earlier messages ({count} more)",diff --git a/src/locales/pt-br.json b/src/locales/pt-br.jsonindex bc1e00a940..61c5b57a2b 100644--- a/src/locales/pt-br.json+++ b/src/locales/pt-br.json@@ -2610,6 +2610,8 @@"chat.export.download": "Baixar como .md","chat.export.copyConversation": "Copiar conversa","chat.export.downloadConversation": "Baixar conversa",+ "chat.export.historyGone": "O histórico da conversa no momento da exportação não está mais disponível",+ "chat.export.branchGone": "O ramo selecionado da conversa não está mais disponível","chat.usage.menu": "Uso","chat.conversationWith": "Conversa com {name}","chat.showEarlier": "Ver mensagens anteriores (mais {count})",