Adds `relationships: Record<string, string[]>` to the VaultEntry interface. Updates mock data with realistic relationship fields (Has, Topics, Owner, Notes) and adds essay mock entries for testing the context view. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
39 lines
950 B
TypeScript
39 lines
950 B
TypeScript
export interface VaultEntry {
|
|
path: string
|
|
filename: string
|
|
title: string
|
|
isA: string | null
|
|
aliases: string[]
|
|
belongsTo: string[]
|
|
relatedTo: string[]
|
|
status: string | null
|
|
owner: string | null
|
|
cadence: string | null
|
|
modifiedAt: number | null
|
|
createdAt: number | null
|
|
fileSize: number
|
|
snippet: string
|
|
/** Generic relationship fields: any frontmatter key whose value contains wikilinks. */
|
|
relationships: Record<string, string[]>
|
|
}
|
|
|
|
export interface GitCommit {
|
|
hash: string
|
|
shortHash: string
|
|
message: string
|
|
author: string
|
|
date: number // unix timestamp
|
|
}
|
|
|
|
export interface ModifiedFile {
|
|
path: string
|
|
relativePath: string
|
|
status: 'modified' | 'added' | 'deleted' | 'untracked' | 'renamed'
|
|
}
|
|
|
|
export type SidebarSelection =
|
|
| { kind: 'filter'; filter: 'all' | 'favorites' }
|
|
| { kind: 'sectionGroup'; type: string }
|
|
| { kind: 'entity'; entry: VaultEntry }
|
|
| { kind: 'topic'; entry: VaultEntry }
|