Skip to content

basalt/v0.12.5

Latest

Choose a tag to compare

@erikjuhani erikjuhani released this 16 May 21:20
· 45 commits to main since this release
5329099

0.12.5 (May, 16 2026)

Added

Allows opening an arbitrary directory as a vault by setting the env var,
skipping the splash screen and going straight to the explorer.

The scrollbar is now visible in both splash screen and the vault
selector modal. It's not optimal, but I realized that vault selection
needs a rewrite, thus I didn't bother to do this properly for example
the scrollbar is always shown if we have more than 4 items regardless if
we have space to show all items and not needing a scrollbar.

Initial CLI layer with --version and --help flags. The version output is
in a "standard" format similar to cargo version output 0.12.5 (abc123def 2026-05-15).

The values are populated by a build phase (compile time) using env vars.

Changed

The rename input in explorer pane was fixed to left border of explorer
pane, and forced vision to jump in deeply nested fields. This commit
adds indentation to the floating rename input which is calculated by the
depth of the explorer item. Additionally added depth field to items.

CreateUntitledNote and CreateUntitledFolder now resolve a target
directory from the explorer's current item (the directory itself, a
file's parent, or the vault root as fallback) instead of always creating
at the vault root. After creation the explorer expands that directory so
the new item is visible.

Add an explorer Open message that always expands a directory rather than
toggling, backed by a new ExplorerState::open. The existing toggle
behavior moves to a Select message, and the ExplorerOpen command and
shell-return path now map to Select. toggle_item_in_tree takes an
always_open flag to support both.

Bump basalt-core to 0.9.0 version in basalt`

Dependencies

  • c2e878a Pin dependencies by @renovate-updater[bot]
datasource package from to
crate indoc 2.0.7 2.0.7
crate insta 1.46.3 1.43.2
crate tempfile 3.26.0 3.23.0
  • 2fac95c Update Rust crate insta to v1.47.2 by @renovate-updater[bot]
datasource package from to
crate insta 1.43.2 1.47.2

Fixed

Backspace at the start of a block's text buffer used to do
nothing. It now merges the current block into the previous one,
preserving in-progress edits. The merge is a no-op when previous
and current block indices coincide, so backspace at the start of
the first block does not collapse the only AST node.

Supporting changes:

  • Add previous_block_idx, rename current_block to
    current_block_idx. Both return owned usize.
  • Add TextBuffer::insert_at_start, which prepends bytes and
    moves both the live and original source range starts so a
    later commit overwrites the joined region.
  • Walk children recursively in shift_nodes via a new
    ast::Node::children_as_mut. Without this the cursor lands on
    a stale child range after editing a paragraph above a list.
  • commit_text_buffer re-parses on buffer.modified rather
    than on content change, since the merge mutates ast_nodes in
    place and a buffer that round-trips needs a re-parse.
  • In update_layout's deferred init, pick the editing block by
    cursor source offset, not by a stale virtual_row lookup.
  • Rename insertion_offset to source_pos.

A heading's source range can include a paragraph that follows it
when the user types a newline mid-edit. The raw renderer treated
the whole range as one heading line, so the new content was
invisible until exit. Split on the first newline in raw mode and
render the rest with render_raw.

Also drop the synthetic empty trailer in raw mode so paragraphs
don't gain a stray blank row when entering edit mode.

ensure_cursor_visible was comparing cursor.virtual_row
against viewport.top() and a viewport.bottom() shrunk by
meta_len. The meta rows live above the content, so the cursor's
screen row is virtual_row + meta_len. The old comparison
scrolled the editor up too early when the meta header was
visible, hiding the first content rows.

Add meta_len to the cursor's screen position before comparing
against the viewport bounds, thread it through CursorWidget so
it draws at the same offset, and add Viewport::scroll_up so
vertical motion that consumes more rows than the viewport
contains scrolls the document.

map_to_item handled VaultEntry::File via Item::from, which
hardcodes depth: 0. Files still rendered correctly, but the rename
input modal positions from Item::depth(), placing it flush-left for
nested files.

Toggling a folder open or closed re-emitted SelectNote for the currently
selected note, which rebuilt the note editor and reset its viewport
scroll position.

Explorer state open() and select() now report (bool) whether a note
was actually selected, and the explorer only emits SelectNote in that
case, which then effectively retains the scroll position of the
viewport.

Pass the configured symbol preset into StatusBar so the active component
badge falls back to ASCII-safe glyphs when the Ascii preset is selected.