refactor: Change to chat conversation

This commit is contained in:
Petr Mironychev
2026-06-11 14:06:19 +02:00
parent 05fe38e289
commit 7bfe9d6f0e
17 changed files with 940 additions and 1243 deletions

View File

@@ -325,9 +325,10 @@ Templates::ContextData Session::buildLegacyContext(
} else if (auto *sa = dynamic_cast<StoredAttachmentContent *>(block)) {
if (!loader)
continue;
const QString text = loader(sa->storedPath());
if (text.isEmpty())
const QString stored = loader(sa->storedPath());
if (stored.isEmpty())
continue;
const QString text = QString::fromUtf8(QByteArray::fromBase64(stored.toUtf8()));
ContentBlockEntry e;
e.kind = ContentBlockEntry::Kind::Text;
e.text = QStringLiteral("File: %1\n```\n%2\n```")