fix: also display contact names stored in name.full #179

This commit is contained in:
Linus Rath
2026-04-11 20:15:49 +02:00
parent 88d87be685
commit 457400ceee
3 changed files with 19 additions and 8 deletions
+1 -1
View File
@@ -564,7 +564,7 @@ function generateSingleVCard(contact: ContactCard): string {
const suffix = components.find(c => c.kind === "suffix")?.value || "";
const additional = components.find(c => c.kind === "additional")?.value || "";
const fn = [prefix, given, additional, surname, suffix].filter(Boolean).join(" ");
const fn = [prefix, given, additional, surname, suffix].filter(Boolean).join(" ") || contact.name?.full || "";
if (fn) {
lines.push(`FN:${encodeValue(fn)}`);
lines.push(`N:${encodeValue(surname)};${encodeValue(given)};${encodeValue(additional)};${encodeValue(prefix)};${encodeValue(suffix)}`);