Skip to content

New UI - #3

Merged
phoscoder merged 36 commits into
mainfrom
new-ui
Oct 2, 2026
Merged

phoscoder merged 36 commits into
mainfrom
new-ui

Conversation

@phoscoder

Copy link
Copy Markdown
Owner

No description provided.

The app is being rewritten natively in Rust with GPUI. The web UI, its npm
tooling and the Tauri configuration go; the Rust backend stays and is
moved in the next commit.
Move the Rust sources to the repository root and drop the Tauri plumbing:
command attributes, State/AppHandle arguments, the file-dialog commands and
the Omarchy theme reader (native theming comes from gpui-omarchy). Commands
now take &DbState. Data stays in ~/.local/share/com.chelete.app so existing
databases keep working. The Makefile drives cargo instead of npm.
Cents-based formatters ported from the web UI (signed, compact, balance),
a strict parser for typed amounts, a lenient one for free-form numeric
fields, and account type labels.
A small JSON file next to the database; starts with the sidebar's collapsed
state and tolerates missing or unknown fields.
A Pager with clamped pages, index ranges, a '1-25 of 61' label and the
per-page options the web UI offered.
Today through Last Year, All Time and Custom, as inclusive ISO date strings
that compare directly against transaction dates. Weeks start on Sunday.
Uses local dates; the web UI went through UTC and could be off by a day.
Frequencies and labels, the next-payment calculation (including the web
UI's month-overflow behaviour, but in local time), and helpers to filter
by frequency and total amounts.
Straight-line projections over weeks, months or years, normalising
subscription costs to a period. Carries over every case from the web UI's
test suite.
Income, expense and net totals, savings rate (rounded half up like the web
UI), per-category breakdowns sorted largest first, and type/account/date
filtering of transactions.
Transactions to CSV with account and category names resolved and fields
quoted where needed, or the whole dataset to JSON.
Column assignment (one column per field), readiness for preview, duplicate
flagging within a file, and per-layout remembered mappings, on top of the
existing parser. Tested against real CSV files.
The import compared rows only against transactions already in the database,
so a file that repeated a row imported it twice even though the preview
marked it as a duplicate. Rows imported earlier in the same file now count.
Adds tests for the transaction, transfer, import and overview commands.
A sidebar for the seven views with Lucide icons, Ctrl+O/T/A/C/U/P/S
navigation, Ctrl+B to collapse (remembered between runs), and a Ctrl+K
command palette. The Overview shows balances and recent transactions from
the existing backend; the other views are placeholders for now. Headless
tests drive the real keybindings.
Account cards with add, transfer and delete. Introduces the shared widget
layer (page headers, labelled fields, modals, selects, inputs) and toasts
that screens raise through ScreenEvent.
Expense and income lists with record counts, add/edit forms and an icon
picker drawn from the asset bundle (two Lucide icons were renamed since
categories were first saved, so those names are aliased). Settings shows the
theme, currency and an About card; the rounded-corners option is dropped
because gpui-omarchy draws square controls.
gpui-omarchy styles its own controls, but gpui-component widgets (the date
picker) read a separate theme. Copy the Omarchy palette across at startup
and whenever the system theme changes, and wrap the single and range date
pickers so screens deal in NaiveDate.
Frequency filter and totals, a paginated table with bulk selection and a
confirmation before deleting, view/edit/add dialogs with the date picker,
and one-click payments that record an expense. Adds the shared list widgets
(checkboxes, pagination bar, confirm dialog).
Inputs for starting balance, income, expense (manual or the total of active
subscriptions) and period, with stat cards and a balance-over-time line
chart that turns red and marks zero when the balance goes negative. Input
validation is a pure function with its own tests.
A preset dropdown that reveals gpui-kit's two-month range picker (with
Last 7/30 days, This/Last month and This year shortcuts) when Custom Range is
chosen. Table cell and dim-text helpers move into the widget layer so more
screens can use them.
Date filtering, a paginated table with bulk selection, add/edit/view
dialogs (the category list follows the Expense/Income toggle), deletion with
confirmation that reverses balances, and CSV/JSON export through the native
save dialog.
Choose a file with the native picker, review the auto-detected column
mapping and defaults, preview the first rows with errors and duplicates
flagged, then import and see the counts. Mappings are remembered per CSV
layout. Wired into Transactions and the command palette.
Date, type and account filters, income and expense donuts coloured by
category, account balances, a paginated recent-transactions table and a
welcome state. The screen is now an entity that reloads when revisited.
Removes the placeholder screen and adds toast and render tests.
Every dialog handles Escape through a shared Modal key context, dialogs
without text fields take focus themselves so Escape still reaches them, and
pressing Enter in a form field submits the form.
The app id ("chelete") is what window rules and desktop entries match on;
without it the window had an empty class.
Run cargo test in CI, build release tarball, AppImage and .deb from the
cargo binary, read the version from Cargo.toml in the bump script, install
the GPUI system libraries in the Dockerfile, and package the AUR entry from
the release tarball. Adds a desktop entry matching the window class.
Document the dependencies, make targets, data location and keyboard
shortcuts in place of the Tauri and npm instructions.
This is an application with pinned, fast-moving GPUI dependencies, so builds
should be reproducible; CI builds with --locked.
A periodic-table style tile reading 17 / Ch / Chlorine. The sidebar shows it
with the name along the bottom (just number and symbol when collapsed) and
the About card adds the atomic mass 35.45. The tile is set in the font chosen
with `omarchy font set`, read from fontconfig by gpui-omarchy, so it matches
the terminal.
gpui-omarchy defaults to the platform UI font, which resolves to Adwaita Sans
here, while Omarchy sets one font with `omarchy font set`. Swap it for that
font in both control libraries and put it back after every palette change,
so the sidebar, tables, dialogs and date picker match the terminal.
Tables, lists and labels outside the controls had no explicit size and
inherited the window default, which looked large next to the 12px controls;
give the shell root the same 0.75rem body size.
A percentage of the toolkit's 16px base, offered in nine steps from 70% to
200% with 110% as the default, plus helpers to step it up or down and to
convert it to a pixel size. Preference files written before this existed
still load.
A Text size dropdown in Settings (70% to 200%) and Ctrl +, Ctrl - and Ctrl 0
shortcuts. Everything is sized in rems, so the setting scales the base size
the way a browser zoom does. The window root re-applies the gpui-component
theme's font_size as the rem size on every frame, so that value carries the
setting; changing only the window's own rem size is undone on the next frame.
The choice is remembered and the dropdown and shortcuts stay in step.

Tests open the window the way main does (through Root, which plain test
windows skip) and check the laid-out sidebar width at several sizes.
@phoscoder
phoscoder merged commit ad3f3c9 into main Oct 2, 2026
2 checks passed
@phoscoder
phoscoder deleted the new-ui branch October 2, 2026 14:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant