Replace setTimeout-based editingKey activation with a useEffect that
watches propertyEntries. When the newly added property appears in
propertyEntries (after the async backend write completes), the effect
sets editingKey, ensuring the editor/picker opens regardless of timing.
The old setTimeout(fn, 0) approach raced with the async frontmatter
write — editingKey was set before the property existed in the DOM,
so the editing state had no matching PropertyRow to activate.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
View filters that reference custom properties (e.g. "Trashed", "Priority")
were not reactively updating because contentToEntryPatch and
frontmatterToEntryPatch only synced known fields (type, status, etc.)
to the VaultEntry. Custom frontmatter keys were silently dropped.
Now frontmatterToEntryPatch produces a propertiesPatch for unknown keys,
and contentToEntryPatch includes them in the properties field. This
ensures evaluateView sees up-to-date custom property values when
re-filtering the note list.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Each view in the sidebar now shows a count chip displaying the number of
notes matching its filters, consistent with type section count chips.
Count updates reactively as vault entries change.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Wrap fireEvent.keyDown calls in act() and assertions in waitFor() so
React state updates flush before checking side effects.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
When CI=true, skip injecting __DEMO_VAULT_PATH__ so the CI runner's
absolute path (/Users/runner/...) is never compiled into the bundle.
The default vault path is resolved at runtime via get_default_vault_path.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
gray_matter mis-parses certain YAML patterns common in Notion-imported notes:
- Unquoted colons in list items (`- Bitcoin: Net Unrealized`) become objects
- Hash characters in list items (`- # Heading`) become nulls
These caused serde deserialization of the entire Frontmatter struct to fail,
silently dropping type, _organized, and all other fields (178 affected notes).
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- Rust: extract_title now prioritizes H1 > frontmatter > filename
- Rust: add has_h1 field to VaultEntry for frontend TitleField control
- Frontend: hide TitleField + icon picker when note has H1 in body
- Frontend: breadcrumb shows filename stem instead of display title
- Frontend: new notes use untitled-{type}-{timestamp}.md, no title in frontmatter
- CSS: only hide first H1 in BlockNote when TitleField is visible
- Updated all tests for new title resolution and note creation behavior
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
The previous shortcut (Cmd+Option+I) conflicted with the editor's
italics shortcut (Cmd+I) on some keyboard layouts. Cmd+Shift+L has
no conflicts.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Remove all vestiges of the abandoned Trash system: trashed/trashedAt fields
from types, frontmatter parsing, sidebar filtering, editor banners, inspector
components, mock data, and all related tests. Delete is already permanent via
useDeleteActions with a confirmation dialog. Notes with trashed:true in
existing vault frontmatter are now treated as normal notes (the flag is
ignored by the parser).
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
The keyboard navigation was computing its own note list with hardcoded
sortByModified, which didn't match the actual UI order (Inbox sorts by
createdAt, custom types use configurable sorts, etc.). Now the NoteList
component writes its sorted list to a shared ref that the navigation
hook reads directly, ensuring navigation always matches visual order.
Also fixes navigation not wrapping at list boundaries per spec.
Syncs CodeScene thresholds with current remote scores.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Remove the collapsed/expanded toggle from SuggestedRelationshipSlot so
the InlineAddNote "Add" button with dashed border is visible without
a click. Also change relationship label font-size from font-mono-overline
(10px) to text-[12px] to match property names in the Inspector.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Add text-left to the suggested property button (browsers default buttons
to text-align: center) and remove text-right from the em-dash placeholder
so both label and value columns match the real property row alignment.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Added paddingBottom: 4 to the expanded Favorites list container,
consistent with the ViewsSection pattern. This creates symmetric
spacing above the first and below the last favorite item.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Changed DEFAULT_SELECTION from 'all' (All Notes) to 'inbox' so the
app always opens on the Inbox section. During a session the user's
navigation is preserved; on next launch or vault switch it resets
to Inbox.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
TypeScript error: forceRawMode was set in the props object but not
declared in the ActiveTabBreadcrumb type or forwarded to BreadcrumbBar.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Non-markdown text files (.yml, .yaml, .json, etc.) are already forced
into raw editor mode via effectiveRawMode. This hides the Raw toggle
button in the breadcrumb bar for those files since toggling is not
applicable. Adds tests for classify_file_kind and forceRawMode behavior.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
The FilterBuilder autocomplete now stores wikilinks as [[stem|title]]
(e.g., [[monday-112|Monday 112]]) instead of just [[title]]. The view
filter comparison uses wikilinkEquals() to match any combination of
path and alias parts, so [[monday-112|Monday 112]] matches
[[monday-112|Monday #112]] via the shared path "monday-112".
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
The dropdown was position:absolute inside a scrollable container with
overflow-y:auto, causing it to be clipped. Now uses createPortal to
render to document.body with position:fixed, escaping the dialog's
overflow. Also adds proper CSS for menu items (font-size 12px, aligned
icon+text, compact padding) via .wikilink-menu--filter modifier.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Use prop-driven data-title-hidden attribute in BreadcrumbBar when rawMode or
diffMode is true. This avoids the timing issue where the useEffect DOM mutation
fired after paint with a null ref, causing the title to never appear.
The IntersectionObserver-based scroll detection is preserved for normal editor
mode (title shows in breadcrumb when title section scrolls out of view).
The SelectContent had overflow-y-auto which caused the browser to handle
scrolling instead of Radix UI's internal scroll mechanism. This made the
SelectScrollDownButton (chevron ▼) non-functional. Changing to
overflow-hidden lets Radix's Viewport manage scrolling, making the
scroll buttons work as intended.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Types created via "Create Type" now appear in the sidebar immediately,
even before any notes of that type exist. The buildDynamicSections
function now adds all active (non-trashed/archived) type definitions
from typeEntryMap to the active types set, using name === entry.title
guard to avoid duplicate entries from lowercase aliases.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Implement silent background cleanup of notes that have been in trash
for more than 30 days, fulfilling the promise already shown in the
Trash view UI.
Safety model (all 5 checks must pass per file):
- _trashed: true in frontmatter
- _trashed_at present and parseable as date
- Date strictly >30 days ago
- File exists on disk
- File path inside vault root
Uses trash::delete (OS trash) with fs::remove_file fallback.
Triggers on app launch and window focus (max once/hour).
Audit log at .laputa/purge.log. Dry-run mode for testing.
Also fixes pre-commit hook to read CodeScene thresholds from
.codescene-thresholds instead of hardcoded values, matching the
ratchet mechanism documented in CLAUDE.md.
ADR-0042 documents the safety model.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Added isMarkdown check to isInboxEntry so .yml, .json, and binary files
no longer appear in the Inbox. All other views (All Notes, Archive,
Trash, Sections, Views) already filter by markdown. FOLDERS still shows
all file types.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
When a .yml file is opened in the raw editor, the breadcrumb bar now
shows the YAML `name` field (e.g., "Active Projects") instead of the
filename. Falls back to filename if no name field is present.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Native <input type="date"> replaced with styled Calendar + Popover component
that matches Laputa's design language. Date values serialize to ISO strings.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
In Changes view, the note list now shows:
- Filesystem filename (e.g. `my-note.md`) instead of the note title
- Change type icon on the right: · (modified), + (added/untracked), − (deleted), R (renamed)
- Clicking a file auto-triggers diff mode via the existing diffToggleRef
Other views (Inbox, All Notes, types, folders) are unaffected.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Adds a scoped wildcard CSS override on .editor__blocknote-container
that sets transition: none and animation: none on all child elements.
Only affects the editor internals — app-wide UI (dialogs, sidebar,
breadcrumb, icon buttons) retains its animations.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Remove unused entries/selection/onSelect props from TypesSection caller.
Add kind narrowing guard for selection.type access in NoteList.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
The OpenAI and Google AI key fields were unused — no feature reads them.
Removes the UI section, KeyField component, and all related state/storage
code across frontend (types, hooks, mock handlers, tests) and Rust backend.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Add title and sidebar_label mappings to contentToEntryPatch so editing
these frontmatter fields in the raw editor immediately updates the note
list, breadcrumb bar, sidebar sections, and inspector.
Also trigger reloadViews() when .yml view files are saved, so sidebar
view names update without a full vault reload.
ADR-0043 documents the reactive update model.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
The cache's git helper functions (collect_md_paths_from_diff,
collect_md_paths_from_porcelain, git_uncommitted_files) filtered for
.md files only. This meant .yml view files created by save_view were
never detected by the incremental cache update, so they didn't appear
in vault entries until a full rescan.
Renamed the helpers to collect_paths_from_diff/collect_paths_from_porcelain
and replaced the .md filter with a hidden-segment filter, matching the
behavior of scan_all_files which already includes all non-hidden files.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
The buildDynamicSections now includes type definitions with 0 instances.
Update the 'does not show section for type with zero active entries' test
to assert the new intended behavior: types with 0 notes appear in the
sidebar as long as their Type definition entry exists (not trashed/archived).
The 'selects result on Enter' test could fail intermittently because
fireEvent.keyDown(window) fired before the useEffect re-registered
the keyboard handler after results loaded. Wrapping in act() ensures
effects are flushed before the event dispatches.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
The frontend already supported body content filtering in Views, but the
Rust backend evaluate_condition() was missing the "body" field mapping.
This adds the mapping from "body" to entry.snippet and comprehensive
tests for contains, not_contains, combined filters, and is_empty.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- CheckCircle button in breadcrumb bar toggles _organized property
- Green filled icon when organized, gray outline when not
- Command palette: "Mark as Organized" / "Mark as Unorganized"
- _organized hidden from Properties panel
- Handler follows favorite toggle pattern with optimistic updates
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>