Repository navigation
GH-95, GH-96, GH-97: filter the move picker, complete the selection footer, bold only the selection - #98
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Three issues on one branch, one commit each, as requested.
Closes #95
Closes #96
Closes #97
#95 — the move picker filters by typed folder name
mused to offer every mailbox with arrow-key navigation only. Typing nownarrows the list, using the same crisp fuzzy match as
/(sahilm/fuzzy,membership only, folder order preserved).
bound to an action the picker honours still does it, so a rebound
esc,enter,morquitworks here. With the shipped mapqcloses andesccloses; letters bound to actions this picker does not honour (
d,f,A,u, ...) are text. That is the line that makes filtering usable withouttaking a rebound key hostage.
keeps its rows, and it reports
no folders matchrather than an empty box.enterwith no match saysno folders matchand leaves the picker open; itnever moves to a folder nobody chose.
type:filterwhile the picker is open.#96 — the footer lists every bulk action and the count
selected N message(s)and then everyaction the range supports: delete, archive, junk, move, flag, read, cancel,
extend, quit. Previously it listed only delete, flag, move, quit, cancel,
extend, so archive and junk looked unavailable in exactly the mode they work.
actionUIDs(), so it names what the next action willactually touch (thread rows and filters included), not a raw index span.
a longer count would overflow,
packHintsdrops whole hints from the tail.selectiongroup (start/clear, extend, delete/archive/junk/move/flag/read selected, cancel) and two
modalsrows for the picker's typing andbackspace. The all-groups help test moved from 140x60 to 140x80: the property
is that every group renders, not that the map fits one particular window.
j/kanywhere:TestNoHintNamesJOrKstill scans every footer context,and the range extends with the arrows.
#97 — bold marks only the selection
Unread rows used
UnreadStyle(bold), and the cursor and range usedSelectedStyle(also bold), so bold marked every unread message and theselection was invisible. Unread now renders in
NormalStyleand keeps the*marker; bold is the cursor and the active range only.
UnreadStyleis removedrather than left unused.
This is what makes the #96 range visible: the count says how many, the bold says
which rows.
Verification
gofmt -l .empty,go vet ./...clean.go test -count=1 ./...ok;go test -race -count=1 ./...ok.go test ./tui -cover -count=191.4% (floor 89.1).golangci-lint v2.15.00 issues.RED before GREEN, quoted:
moveFilter/moveMatchesfields, then failed onbehaviour (
moved 0 times,esc left the picker open,query = "qesc").want it to name one selected message) andthe old help (
help is missing "selection").row 1 is bold while only the cursor is selected.Not included: #69 (the live-gate record) needs the real account and the Fastmail
web UI.