feat: add icon and color fields to VaultEntry

- Add icon (string|null) and color (string|null) to VaultEntry interface
- Update Rust VaultEntry struct and frontmatter parsing to read icon/color
- Add icon/color to SKIP_KEYS so they don't appear as relationships
- Set mock data: Recipe type → cooking-pot/orange, Book type → book-open/green
- Update all test files with the new required fields

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
lucaronin
2026-02-21 13:23:10 +01:00
parent a7addf127e
commit f36cfd1808
8 changed files with 117 additions and 2 deletions

View File

@@ -25,6 +25,8 @@ const mockEntries: VaultEntry[] = [
relationships: {
'Related to': ['[[topic/software-development]]'],
},
icon: null,
color: null,
},
{
path: '/Users/luca/Laputa/note/facebook-ads-strategy.md',
@@ -45,6 +47,8 @@ const mockEntries: VaultEntry[] = [
'Belongs to': ['[[project/26q1-laputa-app]]'],
'Related to': ['[[topic/growth]]'],
},
icon: null,
color: null,
},
{
path: '/Users/luca/Laputa/person/matteo-cellini.md',
@@ -62,6 +66,8 @@ const mockEntries: VaultEntry[] = [
fileSize: 320,
snippet: 'Sponsorship manager.',
relationships: {},
icon: null,
color: null,
},
{
path: '/Users/luca/Laputa/event/2026-02-14-kickoff.md',
@@ -79,6 +85,8 @@ const mockEntries: VaultEntry[] = [
fileSize: 512,
snippet: 'Project kickoff meeting notes.',
relationships: {},
icon: null,
color: null,
},
{
path: '/Users/luca/Laputa/topic/software-development.md',
@@ -96,6 +104,8 @@ const mockEntries: VaultEntry[] = [
fileSize: 256,
snippet: 'Frontend, backend, and systems programming.',
relationships: {},
icon: null,
color: null,
},
]