2026-04-13 19:37:59 +02:00
|
|
|
import type { AiAgentId } from './lib/aiAgents'
|
2026-04-29 00:52:27 +02:00
|
|
|
import type { AiAgentPermissionMode } from './lib/aiAgentPermissionMode'
|
2026-05-03 16:15:03 +02:00
|
|
|
import type { AiModelProvider } from './lib/aiTargets'
|
2026-04-24 22:26:07 +02:00
|
|
|
import type { ThemeMode } from './lib/themeMode'
|
2026-04-26 08:18:47 +02:00
|
|
|
import type { AppLocale } from './lib/i18n'
|
2026-05-11 13:46:18 +02:00
|
|
|
import type { DateDisplayFormat } from './utils/dateDisplay'
|
2026-04-13 19:37:59 +02:00
|
|
|
|
2026-02-14 18:54:27 +01:00
|
|
|
export interface VaultEntry {
|
|
|
|
|
path: string
|
|
|
|
|
filename: string
|
|
|
|
|
title: string
|
2026-05-08 00:45:21 +02:00
|
|
|
workspace?: WorkspaceIdentity
|
2026-02-14 18:54:27 +01:00
|
|
|
isA: string | null
|
|
|
|
|
aliases: string[]
|
|
|
|
|
belongsTo: string[]
|
|
|
|
|
relatedTo: string[]
|
|
|
|
|
status: string | null
|
2026-03-18 01:56:33 +01:00
|
|
|
// Note: owner and cadence are now stored in the generic `properties` map,
|
|
|
|
|
// accessed via entry.properties?.Owner and entry.properties?.Cadence
|
2026-02-21 16:36:06 +01:00
|
|
|
archived: boolean
|
2026-02-14 18:54:27 +01:00
|
|
|
modifiedAt: number | null
|
2026-02-15 12:54:11 +01:00
|
|
|
createdAt: number | null
|
2026-02-14 18:54:27 +01:00
|
|
|
fileSize: number
|
2026-02-17 17:14:29 +01:00
|
|
|
snippet: string
|
2026-02-26 20:50:29 +01:00
|
|
|
wordCount: number
|
2026-02-17 19:08:42 +01:00
|
|
|
/** Generic relationship fields: any frontmatter key whose value contains wikilinks. */
|
|
|
|
|
relationships: Record<string, string[]>
|
2026-02-21 13:23:10 +01:00
|
|
|
/** Phosphor icon name (kebab-case) for Type entries, e.g. "cooking-pot" */
|
|
|
|
|
icon: string | null
|
|
|
|
|
/** Accent color key for Type entries: "red" | "purple" | "blue" | "green" | "yellow" | "orange" */
|
|
|
|
|
color: string | null
|
2026-02-21 17:27:19 +01:00
|
|
|
/** Display order for Type entries in sidebar (lower = higher). null = use default order. */
|
|
|
|
|
order: number | null
|
2026-03-02 02:01:21 +01:00
|
|
|
/** Custom sidebar section label for Type entries, overriding auto-pluralization. */
|
|
|
|
|
sidebarLabel: string | null
|
2026-03-02 08:37:06 +01:00
|
|
|
/** Markdown template for Type entries. Pre-fills new notes created with this type. */
|
|
|
|
|
template: string | null
|
2026-03-03 11:22:04 +01:00
|
|
|
/** Default sort preference for the note list of this Type. Format: "option:direction". */
|
|
|
|
|
sort: string | null
|
2026-03-05 15:26:21 +01:00
|
|
|
/** Default view mode for the note list of this Type: "all", "editor-list", or "editor-only". */
|
|
|
|
|
view: string | null
|
2026-04-29 19:26:24 +02:00
|
|
|
/** Rich-editor note width mode from `_width` frontmatter. null means use the default. */
|
|
|
|
|
noteWidth?: NoteWidthMode | null
|
2026-03-06 21:33:47 +01:00
|
|
|
/** Whether this Type is visible in the sidebar. Defaults to true when absent. */
|
|
|
|
|
visible: boolean | null
|
2026-04-04 20:45:25 +02:00
|
|
|
/** Whether this note has been explicitly organized (removed from Inbox). */
|
|
|
|
|
organized: boolean
|
2026-04-02 14:44:23 +02:00
|
|
|
/** Whether this note is a user favorite (shown in FAVORITES sidebar section). */
|
|
|
|
|
favorite: boolean
|
|
|
|
|
/** Display order within the FAVORITES section (lower = higher). */
|
|
|
|
|
favoriteIndex: number | null
|
2026-04-04 12:52:54 +02:00
|
|
|
/** Properties to display as chips in the note list for this Type's notes. */
|
|
|
|
|
listPropertiesDisplay: string[]
|
2026-02-25 15:04:49 +01:00
|
|
|
/** All wikilink targets found in the note content. Extracted from [[target]] patterns. */
|
|
|
|
|
outgoingLinks: string[]
|
2026-03-03 02:31:18 +01:00
|
|
|
/** Custom scalar frontmatter properties (non-relationship, non-structural). */
|
|
|
|
|
properties: Record<string, string | number | boolean | null>
|
2026-04-06 13:08:17 +02:00
|
|
|
/** Whether the note body has an H1 heading on the first non-empty line. */
|
|
|
|
|
hasH1: boolean
|
feat: show all files in folder view, open text files in raw editor, gray out binary
Vault scanner now includes all files (not just .md). Each VaultEntry has a
fileKind field ("markdown", "text", or "binary") that controls how the
frontend handles it:
- Folder view shows all file kinds; other views (All Notes, type sections)
continue to show only markdown files
- Text files (.yml, .json, .txt, .py, etc.) open in the raw CodeMirror editor
- Binary files (.png, .jpg, .pdf, etc.) appear grayed out and are not clickable
- Non-markdown files use filename as title, skip frontmatter parsing
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 17:38:09 +02:00
|
|
|
/** File kind: "markdown", "text", or "binary". Determines editor behavior.
|
|
|
|
|
* Defaults to "markdown" when absent (for backwards compatibility). */
|
|
|
|
|
fileKind?: 'markdown' | 'text' | 'binary'
|
2026-02-14 18:54:27 +01:00
|
|
|
}
|
2026-02-14 19:35:10 +01:00
|
|
|
|
2026-05-08 00:45:21 +02:00
|
|
|
export interface WorkspaceIdentity {
|
|
|
|
|
id: string
|
|
|
|
|
label: string
|
|
|
|
|
alias: string
|
|
|
|
|
path: string
|
|
|
|
|
shortLabel: string
|
|
|
|
|
color: string | null
|
|
|
|
|
icon: string | null
|
|
|
|
|
mounted: boolean
|
|
|
|
|
available: boolean
|
|
|
|
|
defaultForNewNotes: boolean
|
|
|
|
|
}
|
|
|
|
|
|
2026-02-27 18:17:47 +01:00
|
|
|
export type NoteStatus = 'new' | 'modified' | 'clean' | 'pendingSave' | 'unsaved'
|
2026-02-24 15:54:24 +01:00
|
|
|
|
2026-02-14 20:53:52 +01:00
|
|
|
export interface GitCommit {
|
|
|
|
|
hash: string
|
2026-02-15 12:54:11 +01:00
|
|
|
shortHash: string
|
2026-02-14 20:53:52 +01:00
|
|
|
message: string
|
|
|
|
|
author: string
|
|
|
|
|
date: number // unix timestamp
|
|
|
|
|
}
|
|
|
|
|
|
2026-02-26 20:14:46 +01:00
|
|
|
export interface LastCommitInfo {
|
|
|
|
|
shortHash: string
|
|
|
|
|
commitUrl: string | null
|
|
|
|
|
}
|
|
|
|
|
|
2026-02-15 12:54:11 +01:00
|
|
|
export interface ModifiedFile {
|
|
|
|
|
path: string
|
|
|
|
|
relativePath: string
|
2026-05-11 16:37:06 +02:00
|
|
|
vaultPath?: string
|
2026-02-15 12:54:11 +01:00
|
|
|
status: 'modified' | 'added' | 'deleted' | 'untracked' | 'renamed'
|
2026-04-13 15:22:21 +02:00
|
|
|
addedLines?: number | null
|
|
|
|
|
deletedLines?: number | null
|
|
|
|
|
binary?: boolean
|
2026-02-15 12:54:11 +01:00
|
|
|
}
|
|
|
|
|
|
2026-02-22 13:38:18 +01:00
|
|
|
export interface Settings {
|
feat: auto-pull vault changes from Git (background sync + conflict handling) (#79)
* feat: add auto-pull vault sync with conflict handling
- Add git_pull, has_remote, get_conflict_files to Rust backend
- Add GitPullResult type and auto_pull_interval_minutes to Settings
- Create useAutoSync hook (pull on launch, focus, periodic interval)
- Update StatusBar with real sync status indicator
- Add pull interval setting to SettingsPanel
- Add mock handler for git_pull
- Update existing tests for new Settings field
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* test: add tests for git pull, settings, and useAutoSync hook
- Add Rust tests: has_remote, git_pull (no_remote, up_to_date, updated),
get_conflict_files, parse_updated_files, GitPullResult serialization
- Add frontend tests: useAutoSync (mount pull, focus pull, conflict,
error, manual trigger, concurrent prevention, no_remote)
- Fix existing settings tests for new auto_pull_interval_minutes field
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* design: add auto-pull-vault wireframes
Frames showing: sync idle, syncing, conflict indicator,
settings sync section, and conflict toast notification.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* fix: add auto_pull_interval_minutes to all Settings literals
Fix build error and test fixtures missing the new field.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* fix: cargo fmt
* ci: re-trigger CI after flaky test
* ci: retrigger after disk space cleanup
---------
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-26 01:55:16 +01:00
|
|
|
auto_pull_interval_minutes: number | null
|
2026-04-16 23:38:30 +02:00
|
|
|
autogit_enabled?: boolean | null
|
|
|
|
|
autogit_idle_threshold_seconds?: number | null
|
|
|
|
|
autogit_inactive_threshold_seconds?: number | null
|
2026-04-24 15:04:08 +09:00
|
|
|
auto_advance_inbox_after_organize?: boolean | null
|
2026-03-25 16:05:13 +01:00
|
|
|
telemetry_consent: boolean | null
|
|
|
|
|
crash_reporting_enabled: boolean | null
|
|
|
|
|
analytics_enabled: boolean | null
|
|
|
|
|
anonymous_id: string | null
|
2026-04-03 21:22:28 +02:00
|
|
|
release_channel: string | null
|
2026-04-24 22:26:07 +02:00
|
|
|
theme_mode?: ThemeMode | null
|
2026-04-26 08:18:47 +02:00
|
|
|
ui_language?: AppLocale | null
|
2026-05-11 13:46:18 +02:00
|
|
|
date_display_format?: DateDisplayFormat | null
|
2026-04-29 19:26:24 +02:00
|
|
|
note_width_mode?: NoteWidthMode | null
|
2026-05-04 21:54:06 +02:00
|
|
|
sidebar_type_pluralization_enabled?: boolean | null
|
2026-04-16 12:18:11 +02:00
|
|
|
initial_h1_auto_rename_enabled?: boolean | null
|
2026-05-12 22:30:24 +02:00
|
|
|
ai_features_enabled?: boolean | null
|
2026-04-13 19:37:59 +02:00
|
|
|
default_ai_agent?: AiAgentId | null
|
2026-05-03 16:15:03 +02:00
|
|
|
default_ai_target?: string | null
|
|
|
|
|
ai_model_providers?: AiModelProvider[] | null
|
2026-04-28 08:55:40 +02:00
|
|
|
hide_gitignored_files?: boolean | null
|
2026-04-30 02:02:59 +02:00
|
|
|
all_notes_show_pdfs?: boolean | null
|
|
|
|
|
all_notes_show_images?: boolean | null
|
|
|
|
|
all_notes_show_unsupported?: boolean | null
|
2026-05-11 16:37:06 +02:00
|
|
|
multi_workspace_enabled?: boolean | null
|
2026-02-23 19:56:30 +01:00
|
|
|
}
|
|
|
|
|
|
feat: auto-pull vault changes from Git (background sync + conflict handling) (#79)
* feat: add auto-pull vault sync with conflict handling
- Add git_pull, has_remote, get_conflict_files to Rust backend
- Add GitPullResult type and auto_pull_interval_minutes to Settings
- Create useAutoSync hook (pull on launch, focus, periodic interval)
- Update StatusBar with real sync status indicator
- Add pull interval setting to SettingsPanel
- Add mock handler for git_pull
- Update existing tests for new Settings field
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* test: add tests for git pull, settings, and useAutoSync hook
- Add Rust tests: has_remote, git_pull (no_remote, up_to_date, updated),
get_conflict_files, parse_updated_files, GitPullResult serialization
- Add frontend tests: useAutoSync (mount pull, focus pull, conflict,
error, manual trigger, concurrent prevention, no_remote)
- Fix existing settings tests for new auto_pull_interval_minutes field
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* design: add auto-pull-vault wireframes
Frames showing: sync idle, syncing, conflict indicator,
settings sync section, and conflict toast notification.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* fix: add auto_pull_interval_minutes to all Settings literals
Fix build error and test fixtures missing the new field.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* fix: cargo fmt
* ci: re-trigger CI after flaky test
* ci: retrigger after disk space cleanup
---------
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-26 01:55:16 +01:00
|
|
|
export interface GitPullResult {
|
|
|
|
|
status: 'up_to_date' | 'updated' | 'conflict' | 'no_remote' | 'error'
|
|
|
|
|
message: string
|
|
|
|
|
updatedFiles: string[]
|
|
|
|
|
conflictFiles: string[]
|
|
|
|
|
}
|
|
|
|
|
|
2026-03-07 00:31:46 +01:00
|
|
|
export interface GitPushResult {
|
|
|
|
|
status: 'ok' | 'rejected' | 'auth_error' | 'network_error' | 'error'
|
|
|
|
|
message: string
|
|
|
|
|
}
|
|
|
|
|
|
2026-04-19 16:18:35 +02:00
|
|
|
export interface GitAddRemoteResult {
|
|
|
|
|
status: 'connected' | 'already_configured' | 'incompatible_history' | 'auth_error' | 'network_error' | 'error'
|
|
|
|
|
message: string
|
|
|
|
|
}
|
|
|
|
|
|
2026-03-19 09:51:06 +01:00
|
|
|
export type SyncStatus = 'idle' | 'syncing' | 'error' | 'conflict' | 'pull_required'
|
|
|
|
|
|
|
|
|
|
export interface GitRemoteStatus {
|
|
|
|
|
branch: string
|
|
|
|
|
ahead: number
|
|
|
|
|
behind: number
|
|
|
|
|
hasRemote: boolean
|
|
|
|
|
}
|
feat: auto-pull vault changes from Git (background sync + conflict handling) (#79)
* feat: add auto-pull vault sync with conflict handling
- Add git_pull, has_remote, get_conflict_files to Rust backend
- Add GitPullResult type and auto_pull_interval_minutes to Settings
- Create useAutoSync hook (pull on launch, focus, periodic interval)
- Update StatusBar with real sync status indicator
- Add pull interval setting to SettingsPanel
- Add mock handler for git_pull
- Update existing tests for new Settings field
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* test: add tests for git pull, settings, and useAutoSync hook
- Add Rust tests: has_remote, git_pull (no_remote, up_to_date, updated),
get_conflict_files, parse_updated_files, GitPullResult serialization
- Add frontend tests: useAutoSync (mount pull, focus pull, conflict,
error, manual trigger, concurrent prevention, no_remote)
- Fix existing settings tests for new auto_pull_interval_minutes field
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* design: add auto-pull-vault wireframes
Frames showing: sync idle, syncing, conflict indicator,
settings sync section, and conflict toast notification.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* fix: add auto_pull_interval_minutes to all Settings literals
Fix build error and test fixtures missing the new field.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* fix: cargo fmt
* ci: re-trigger CI after flaky test
* ci: retrigger after disk space cleanup
---------
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-26 01:55:16 +01:00
|
|
|
|
feat: full-text search with qmd backend and SearchPanel UI (Cmd+Shift+F) (#64)
* feat: add search backend (qmd CLI) and design file
- Add search.rs: qmd integration for keyword (BM25), semantic (vsearch),
and hybrid search modes via CLI JSON output
- Register search_vault Tauri command in lib.rs
- Design file with 3 frames: empty, results, no-results states
- Fix pre-existing test failures: install @tauri-apps/plugin-opener,
add mock in test setup
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* feat: add SearchPanel UI with Cmd+Shift+F shortcut
- SearchPanel component: full-text search overlay with keyword/semantic
mode toggle, debounced search (200ms), arrow key navigation, result
count + elapsed time display, note type badges from vault entries
- Cmd+Shift+F shortcut registered in useAppKeyboard
- Mock search_vault handler in mock-tauri for browser dev mode
- SearchResult/SearchResponse types in types.ts
- Tests: 15 new tests for SearchPanel + 2 for keyboard shortcut
- scrollIntoView mock in test setup for jsdom compatibility
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* fix: correct SearchPanel imports for Tauri/browser dual-mode
Use invoke from @tauri-apps/api/core and mockInvoke from mock-tauri
with a searchCall wrapper, fixing the TypeScript build error.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* fix: make test_detect_collection_fallback robust when qmd not installed
* fix: reset localStorage between App tests to prevent view mode state leak
---------
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-25 17:09:50 +01:00
|
|
|
export interface SearchResult {
|
|
|
|
|
title: string
|
|
|
|
|
path: string
|
|
|
|
|
snippet: string
|
|
|
|
|
score: number
|
|
|
|
|
noteType: string | null
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
export interface SearchResponse {
|
|
|
|
|
results: SearchResult[]
|
|
|
|
|
elapsedMs: number
|
|
|
|
|
query: string
|
|
|
|
|
mode: string
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
export type SearchMode = 'keyword' | 'semantic' | 'hybrid'
|
|
|
|
|
|
2026-04-07 20:31:08 +02:00
|
|
|
/** Vault-scoped UI configuration stored locally per vault path. */
|
|
|
|
|
export interface InboxConfig {
|
|
|
|
|
noteListProperties: string[] | null
|
2026-04-10 13:52:39 +02:00
|
|
|
explicitOrganization?: boolean | null
|
2026-04-07 20:31:08 +02:00
|
|
|
}
|
|
|
|
|
|
2026-04-16 02:18:43 +02:00
|
|
|
/** Vault-scoped UI configuration stored locally per vault path. */
|
|
|
|
|
export interface AllNotesConfig {
|
|
|
|
|
noteListProperties: string[] | null
|
|
|
|
|
}
|
|
|
|
|
|
2026-04-27 10:10:58 +02:00
|
|
|
/** Vault-scoped UI configuration stored locally per vault path. */
|
2026-04-26 04:41:18 +02:00
|
|
|
export type NoteLayout = 'centered' | 'left'
|
|
|
|
|
|
2026-04-29 19:26:24 +02:00
|
|
|
export type NoteWidthMode = 'normal' | 'wide'
|
|
|
|
|
|
2026-04-07 20:31:08 +02:00
|
|
|
/** Vault-scoped UI configuration stored locally per vault path. */
|
2026-03-05 15:26:21 +01:00
|
|
|
export interface VaultConfig {
|
|
|
|
|
zoom: number | null
|
|
|
|
|
view_mode: string | null
|
2026-03-17 11:41:35 +01:00
|
|
|
editor_mode: string | null
|
2026-04-26 04:41:18 +02:00
|
|
|
note_layout?: NoteLayout | null
|
2026-04-29 00:52:27 +02:00
|
|
|
ai_agent_permission_mode?: AiAgentPermissionMode | null
|
2026-03-05 15:26:21 +01:00
|
|
|
tag_colors: Record<string, string> | null
|
|
|
|
|
status_colors: Record<string, string> | null
|
|
|
|
|
property_display_modes: Record<string, string> | null
|
2026-04-07 20:31:08 +02:00
|
|
|
inbox?: InboxConfig | null
|
2026-04-16 02:18:43 +02:00
|
|
|
allNotes?: AllNotesConfig | null
|
2026-03-05 15:26:21 +01:00
|
|
|
}
|
|
|
|
|
|
2026-03-05 16:27:29 +01:00
|
|
|
export interface PulseFile {
|
|
|
|
|
path: string
|
|
|
|
|
status: 'added' | 'modified' | 'deleted'
|
|
|
|
|
title: string
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
export interface PulseCommit {
|
|
|
|
|
hash: string
|
|
|
|
|
shortHash: string
|
|
|
|
|
message: string
|
|
|
|
|
date: number
|
|
|
|
|
githubUrl: string | null
|
|
|
|
|
files: PulseFile[]
|
|
|
|
|
added: number
|
|
|
|
|
modified: number
|
|
|
|
|
deleted: number
|
|
|
|
|
}
|
|
|
|
|
|
2026-04-06 12:21:56 +02:00
|
|
|
export type SidebarFilter = 'all' | 'archived' | 'changes' | 'pulse' | 'inbox' | 'favorites'
|
2026-03-19 06:41:40 +01:00
|
|
|
|
|
|
|
|
export type InboxPeriod = 'week' | 'month' | 'quarter' | 'all'
|
feat: reorganize menu bar with Go, Note, and Vault menus
Add missing command palette commands to menu bar and reorganize into
logical groups: File, Edit, View, Go, Note, Vault, Window. New menus
expose navigation filters, note actions, vault management, themes, and
git operations. Context-sensitive items (archive, trash, diff, raw
editor, commit, conflicts) are greyed out when not applicable.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-05 14:13:54 +01:00
|
|
|
|
2026-02-14 19:35:10 +01:00
|
|
|
export type SidebarSelection =
|
feat: reorganize menu bar with Go, Note, and Vault menus
Add missing command palette commands to menu bar and reorganize into
logical groups: File, Edit, View, Go, Note, Vault, Window. New menus
expose navigation filters, note actions, vault management, themes, and
git operations. Context-sensitive items (archive, trash, diff, raw
editor, commit, conflicts) are greyed out when not applicable.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-05 14:13:54 +01:00
|
|
|
| { kind: 'filter'; filter: SidebarFilter }
|
2026-02-14 19:35:10 +01:00
|
|
|
| { kind: 'sectionGroup'; type: string }
|
2026-04-30 00:18:33 +02:00
|
|
|
| { kind: 'folder'; path: string; rootPath?: string }
|
2026-02-14 19:35:10 +01:00
|
|
|
| { kind: 'entity'; entry: VaultEntry }
|
2026-05-12 19:33:53 +02:00
|
|
|
| { kind: 'view'; filename: string; rootPath?: string }
|
2026-04-02 16:09:43 +02:00
|
|
|
|
|
|
|
|
// --- Custom Views ---
|
|
|
|
|
|
|
|
|
|
export type FilterOp = 'equals' | 'not_equals' | 'contains' | 'not_contains' | 'any_of' | 'none_of' | 'is_empty' | 'is_not_empty' | 'before' | 'after'
|
|
|
|
|
|
|
|
|
|
export interface FilterCondition {
|
|
|
|
|
field: string
|
|
|
|
|
op: FilterOp
|
|
|
|
|
value?: unknown
|
2026-04-07 22:51:23 +02:00
|
|
|
regex?: boolean
|
2026-04-02 16:09:43 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
export type FilterGroup = { all: FilterNode[] } | { any: FilterNode[] }
|
|
|
|
|
export type FilterNode = FilterCondition | FilterGroup
|
|
|
|
|
|
|
|
|
|
export interface ViewDefinition {
|
|
|
|
|
name: string
|
|
|
|
|
icon: string | null
|
|
|
|
|
color: string | null
|
2026-04-28 20:41:07 +02:00
|
|
|
/** Display order for saved Views in sidebar/list surfaces (lower = higher). */
|
|
|
|
|
order?: number | null
|
2026-04-02 16:09:43 +02:00
|
|
|
sort: string | null
|
2026-04-18 20:31:25 +02:00
|
|
|
listPropertiesDisplay?: string[]
|
2026-04-02 16:09:43 +02:00
|
|
|
filters: FilterGroup
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
export interface ViewFile {
|
|
|
|
|
filename: string
|
|
|
|
|
definition: ViewDefinition
|
2026-05-12 19:33:53 +02:00
|
|
|
rootPath?: string
|
|
|
|
|
workspace?: WorkspaceIdentity
|
2026-04-02 16:09:43 +02:00
|
|
|
}
|
2026-03-31 11:06:11 +02:00
|
|
|
|
|
|
|
|
/** A node in the vault's folder tree (directories only, no files). */
|
|
|
|
|
export interface FolderNode {
|
|
|
|
|
name: string
|
|
|
|
|
path: string
|
2026-05-11 16:37:06 +02:00
|
|
|
rootPath?: string
|
2026-03-31 11:06:11 +02:00
|
|
|
children: FolderNode[]
|
|
|
|
|
}
|