feat: picker mapping for moving up and down #157

Merged
noe.trevino merged 2 commits from fix/jk-scroll-task-picker into main 2026-08-11 23:58:09 -05:00
Owner

Checklist

  • Read CONTRIBUTING.md
  • Ran tests (go test ./... -race) locally
  • Formatted and linted with gofmt -w . and golangci-lint run ./... respectively
  • Added tests if necessary (significant changes/complex logic)
  • Updated documentation if applicable
  • Updated README.md if applicable

Summary

## Checklist - [x] Read `CONTRIBUTING.md` - [x] Ran tests (`go test ./... -race`) locally - [x] Formatted and linted with `gofmt -w .` and `golangci-lint run ./...` respectively - [x] Added tests if necessary (significant changes/complex logic) - [x] Updated documentation if applicable - [x] Updated `README.md` if applicable ## Summary <!-- What does this PR change and/or fix? Examples: Closes: 54 Fixes: 67 -->
claude[bot] (Migrated from github.com) reviewed 2026-08-11 23:29:14 -05:00
@ -79,2 +81,4 @@
type PickerKeys struct {
DeleteLabel string `yaml:"delete_label"`
MoveUp string `yaml:"move_up"`
MoveDown string `yaml:"move_down"`
claude[bot] (Migrated from github.com) commented 2026-08-11 23:29:14 -05:00

This fix (using dedicated ctrl+-modified picker keys instead of the global Navigation keys so bare letters remain available as filter text) is only applied to the parent/child pickers in update_pickers.go. updateLabelPicker is also a filter-as-you-type picker (it has a "type to filter/search" default case) but still switches on km.Navigation.MoveUp/km.Navigation.MoveDown (defaults "k"/"j"), so typing "k" or "j" to filter labels will move the cursor instead of being added to the filter text — the exact bug this PR fixes elsewhere is left unfixed here.

This fix (using dedicated `ctrl+`-modified picker keys instead of the global `Navigation` keys so bare letters remain available as filter text) is only applied to the parent/child pickers in `update_pickers.go`. `updateLabelPicker` is also a filter-as-you-type picker (it has a "type to filter/search" default case) but still switches on `km.Navigation.MoveUp`/`km.Navigation.MoveDown` (defaults `"k"`/`"j"`), so typing "k" or "j" to filter labels will move the cursor instead of being added to the filter text — the exact bug this PR fixes elsewhere is left unfixed here.
claude[bot] (Migrated from github.com) reviewed 2026-08-11 23:29:16 -05:00
claude[bot] (Migrated from github.com) commented 2026-08-11 23:29:16 -05:00

No test covers these new Pickers.MoveUp/Pickers.MoveDown defaults or their applyDefaultsFrom merge behavior. internal/config/config_test.go asserts default/merge behavior for Pickers.DeleteLabel (added alongside the same struct) but wasn't extended for these new fields, and pickers_interactive_test.go has no case exercising ctrl+j/ctrl+k navigation or verifying that "j"/"k" now reach the filter text in the parent/child pickers.

No test covers these new `Pickers.MoveUp`/`Pickers.MoveDown` defaults or their `applyDefaultsFrom` merge behavior. `internal/config/config_test.go` asserts default/merge behavior for `Pickers.DeleteLabel` (added alongside the same struct) but wasn't extended for these new fields, and `pickers_interactive_test.go` has no case exercising `ctrl+j`/`ctrl+k` navigation or verifying that "j"/"k" now reach the filter text in the parent/child pickers.
@ -79,2 +81,4 @@
type PickerKeys struct {
DeleteLabel string `yaml:"delete_label"`
MoveUp string `yaml:"move_up"`
MoveDown string `yaml:"move_down"`
Author
Owner

Good catch! To implement

Good catch! To implement
noe.trevino left a comment

Looks good to me

Looks good to me
@ -76,8 +76,12 @@ type FormKeys struct {
}
// PickerKeys defines keybindings used within picker overlays.
// MoveUp/MoveDown use ctrl+ modifiers because filter-as-you-type pickers
Author
Owner

@TheNoeTrevino

@TheNoeTrevino
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
noe.trevino/paso!157
No description provided.