fix(coding-agent): respect export theme backgrounds closes #2565

This commit is contained in:
Mario Zechner
2026-03-24 21:27:19 +01:00
parent bab58f821d
commit a949490f29
2 changed files with 6 additions and 4 deletions

View File

@@ -149,10 +149,11 @@ function generateHtml(sessionData: SessionData, themeName?: string): string {
const themeVars = generateThemeVars(themeName);
const colors = getResolvedThemeColors(themeName);
const exportColors = deriveExportColors(colors.userMessageBg || "#343541");
const bodyBg = exportColors.pageBg;
const containerBg = exportColors.cardBg;
const infoBg = exportColors.infoBg;
const themeExport = getThemeExportColors(themeName);
const derivedExportColors = deriveExportColors(colors.userMessageBg || "#343541");
const bodyBg = themeExport.pageBg ?? derivedExportColors.pageBg;
const containerBg = themeExport.cardBg ?? derivedExportColors.cardBg;
const infoBg = themeExport.infoBg ?? derivedExportColors.infoBg;
// Base64 encode session data to avoid escaping issues
const sessionDataBase64 = Buffer.from(JSON.stringify(sessionData)).toString("base64");