basalt-0-13-0.mov
Added
- 7f3e7c3 Move note editor cursor by whole lines, add gj/gk for screen rows by @erikjuhani
j/k now move by whole soft-wrapped lines, matching Vim. On the first line,
k goes to line start; on the last line, j goes to line end. New gj/gk
motions move by single visible rows. Screen movement drives half-page
scroll and jump-to-top so the viewport tracks rows.Wrap continuation is derived from a typed VirtualSpan::WrapMarker span
produced only by render, replacing the stored wrap_continuation flag.
- 18bc817 Make note editor line wrapping configurable by @erikjuhani
Wrapping suits prose, but tables and code read better unwrapped. Add a
wraptoggle (default on); when off, a long line pans horizontally like
code lines already do.
- 8832bc4 Highlight the cursor's line in the note editor by @erikjuhani
Tracking the cursor across wrapped rows is hard. Tint the whole logical
line instead, in read and edit mode, replacing the heavier read-mode
reverse bar. Theline-highlighttheme key sets the colour or turns it off.
- 459d9bd Follow the link under the cursor with gx by @erikjuhani
Add a note editor action that resolves whatever link sits under the
cursor. A wiki link travels to its note, creating the note first when it
does not exist yet. A bare URL or a label markdown link opens in
the platform browser.A single pure scan (motion::link_at) classifies the cursor position into
a LinkTarget, which app.rs resolves against the vault (new
Vault::find_note) or hands to a cross-platform opener (command::open_url).Bound to gx in the vim config and to enter and gd in the default config.
- 2954f5a Add a configurable line-number gutter to the note editor by @erikjuhani
Show line numbers while editing a note. The
line_numbersconfig
accepts "absolute", "relative", or "off" (default "absolute").
- 3f6b8e2 Add single-file mode for opening a markdown file by @erikjuhani
Pass a file path to open one markdown file without a vault:
basalt path/to/note.mdThe file opens in a focused view with only the note editor and the
outline. This view has no explorer pane, and the focus cycle wraps
between the editor and the outline. Basalt creates the file if it does
not exist, and a file path takes precedence over any configured vault.
Opening a vault from the selector switches back to the vault view.Documented the mode in the Files and Folders and Installation pages, and
added a VHS tape to showcase it.
- 07c6c34 Add syntax highlighting to fenced code blocks by @erikjuhani
Fenced code blocks that name a language now get token colours. The
language is the first word of the info string, as a name or a file
extension. The highlighting comes from tree-sitter with the highlight
queries of ten grammars: Rust, TOML, JSON, Bash, JavaScript,
TypeScript, Python, Go, YAML and C. A fence without a known language
renders as plain code, as before.Every theme gets a [syntax] table with a colour for keywords, strings,
comments, functions, types and constants. The bundled themes set the
six colours to fit their palette.In edit mode the cursor's line keeps its colours while it shows the
raw text, and a run of adjacent code lines is parsed once per
keystroke. In read view the tokens of each block are cached by
language and text, so an unchanged block is not parsed again on the
next layout pass.
- 9ab21ae Tag the active READ line with a gutter marker and doc motions by @erikjuhani
READ mode now marks the active line with a slim left-gutter symbol (the
newread_cursorglyph) on top of the line-highlight tint, instead of
relying on the tint alone. It also respects thegg/Gdocument
motions, and Esc or Shift+R leave READ back to the source edit view.
- 188281d Add fuzzy full-text search across vault notes
Open a search modal that fuzzy-matches note content line by line with
frizbee. Ranking runs in two phases: score every line cheaply, then
compute highlight indices for the top results only.The index builds in the background in batches, so results stream in
while indexing runs instead of waiting for the whole vault. Reads and
line splitting run in parallel with rayon. Selecting a result opens the
note at the matched line and column.Move the word and character motions into a shared crate::motion module
so the search input reuses them for query editing.
- 56ff6ff Restore Obsidian's open tabs and write tab state back to workspace.json by @erikjuhani
Vault::workspace() already reads active and lastOpenFiles. Add the main
split/tabs/leaf layout tree, so Workspace exposes the notes open as tabs
and which one is active, in tab order. Add Vault::save_workspace to
write tabs back to workspace.json; only the fields Basalt understands
are touched, so sidebars, other panes and anything else in the file are
left as they were.Read the vault's .obsidian/workspace.json on open and restore every tab
Obsidian had open, in the same order, with the active one focused. Only
the active tab loads its note; the rest stay pending and load lazily on
first focus, or sooner if a background pass reaches them first, so a
vault with many open tabs opens as fast as one with a single note. Tabs
also write back: opening or closing a note, switching tabs and switching
vaults update workspace.json so Obsidian shows the same tabs next time
it opens the vault.This does not merge with changes Obsidian makes to the same vault while
Basalt is running. Whichever one saves last wins, so keep them pointed
at the same vault one at a time.workspace.json is a file Obsidian also owns, and a bug in the write path
could corrupt it, so tabs.sync in config.toml controls it: "off" to not
touch the file at all, "read" (default) to only read tabs from it, or
"write" to also write tab changes back, which is experimental. Tabs
themselves stay available either way.Closes #292
Breaking
- f4cd7f2 Nest editor settings under the [note_editor] table by @erikjuhani
Group the editor settings under the
[note_editor]TOML table:
experimental(wasexperimental_editor),vim_mode, and the new
default_mode("read" or "edit") that picks the view a note opens in.
Edit needs the experimental editor; without it the note opens in Read.
The runtime Config stays flat; only the parsed TOML shape nests.The top-level
experimental_editorandvim_modekeys no longer take
effect and must move under[note_editor].
Changed
- 27bdefa Memoize note layout instead of rebuilding it every frame by @erikjuhani
The editor built the whole layout document on every frame and cloned the
result twice to draw a single screen. This slowed down the editing
experience considerably.By caching the layout on a cache struct of its inputs and skipping the
rebuild when nothing changed, and by cloning only the visible rows. Idle
and scroll frames drop by around ~50ms.Also borrow content in render_node instead of cloning it per block.
- cb6ea18 Use the real terminal cursor for text editing by @erikjuhani
Replace the painted reversed-cell cursor in the note editor and the input
modal with the terminal's own cursor, placed via the frame. The editor keeps
its full-line highlight in read view; edit view exposes a screen position that
the app sets on the frame.Shape the cursor to the focused mode: a narrow bar while inserting text, a
block otherwise. Show it only for the focused component, and restore the
terminal's default shape on exit.
- 8e0fa5a Make blank lines between blocks editable in edit mode by @erikjuhani
Blocks now tile the document: each block's editable span runs from its
start to the next block's start, so the preceding block owns the blank
lines that follow it. The cursor can rest on and edit those blanks,
which previously fell in an unreachable gap between block source ranges.
- 529e607 Default note titles to the script font style by @erikjuhani
The note title derived from a filename rendered in Blackboard Bold
(double-struck) in the unicode and nerd-font presets. The default is now
the script style, which reads as a more title-like hand and matches the
h5/h6 heading styling that already uses it.
- c451756 Preload syntax highlighting grammars in the background at startup by @erikjuhani
Compiling every language grammar takes long enough to stall a note's
first layout. Start that compile in the background as soon as Basalt
starts, instead of blocking whichever note happens to need it first.A note laid out before the compile finishes renders its code blocks
plain and picks up highlighting on its next layout.
Fixed
- 28429e2 Match title text to the symbol preset by @erikjuhani
The
⋅𝕭𝖆𝖘𝖆𝖑𝖙⋅title was hardcoded in the header and the splash modal,
so anasciipreset still emitted the dot operator and Fraktur-bold
glyphs on terminals that cannot render them. Both sites now branch on
the preset and fall back to plainBasaltwhen it isAscii, while
unicode and nerd-font presets keep the stylized form.