mirror of
https://github.com/aleksejs1/obsidian-contact-sync-plugin.git
synced 2026-07-22 05:48:16 +00:00
Update libs, format, version update
This commit is contained in:
parent
d0c907d7f9
commit
e52cf526e2
5 changed files with 873 additions and 485 deletions
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"id": "google-contacts",
|
||||
"name": "Google Contacts",
|
||||
"version": "1.0.7",
|
||||
"version": "1.0.8",
|
||||
"minAppVersion": "1.8.0",
|
||||
"description": "Synchronize your Google contacts with separate contact-notes",
|
||||
"author": "aleksejs1",
|
||||
|
|
|
|||
1347
package-lock.json
generated
1347
package-lock.json
generated
File diff suppressed because it is too large
Load diff
|
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
"name": "google-contacts",
|
||||
"version": "1.0.7",
|
||||
"version": "1.0.8",
|
||||
"description": "",
|
||||
"main": "rollup.config.js",
|
||||
"type": "module",
|
||||
|
|
|
|||
|
|
@ -142,9 +142,8 @@ export class ContactNoteWriter {
|
|||
prefix: string
|
||||
): string | null {
|
||||
// Try displayName first, then organization name, then fall back to ID
|
||||
const name = contact.names?.[0]?.displayName ||
|
||||
contact.organizations?.[0]?.name ||
|
||||
id;
|
||||
const name =
|
||||
contact.names?.[0]?.displayName || contact.organizations?.[0]?.name || id;
|
||||
if (!name) return null;
|
||||
const safeName = name.replace(/[\\/:*?"<>|]/g, '_');
|
||||
const filename = normalizePath(`${folderPath}/${prefix}${safeName}.md`);
|
||||
|
|
|
|||
|
|
@ -19,7 +19,7 @@ export class Formatter {
|
|||
) {
|
||||
// Try to get name from contact.names first
|
||||
const displayName = contact.names?.[0]?.displayName;
|
||||
|
||||
|
||||
if (displayName) {
|
||||
this.addContactFieldToFrontmatter(
|
||||
frontmatterLines,
|
||||
|
|
|
|||
Loading…
Reference in a new issue