From a91be01e856b75a2abc31cc00e9a46a506e0c9df Mon Sep 17 00:00:00 2001 From: Cliff Brake Date: Wed, 15 Jul 2026 13:47:37 -0400 Subject: [PATCH 1/3] fix: keep TUI filter applied after copy, delete, add, and edit updateTableForSelectedFile rebuilt the table and reset the view to all rows, dropping any active search or parametric filter. Reapply the active filter after the rebuild so it stays in effect across mutations. --- CHANGELOG.md | 4 ++++ tui.go | 23 +++++++++++++++++++++-- 2 files changed, 25 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index fba2a1d..fe60c9d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -11,6 +11,10 @@ For more details or to discuss releases, please visit the ## [Unreleased] +- TUI: an active search or parametric filter now stays applied after copying, + deleting, adding, or editing a part. The list previously reverted to showing + every row until the filter was re-entered. + ## [0.9.1] - 2026-07-15 - TUI: the parts list now scrolls a full page at a time with Ctrl-F (forward) diff --git a/tui.go b/tui.go index 8889c82..b9f368e 100644 --- a/tui.go +++ b/tui.go @@ -431,10 +431,29 @@ func (m *modelNew) updateTableForSelectedFile() { m.isEditable = true } - m.filteredRows = m.allRows - m.rowToDataIdx = nil m.mode = modeNormal m.error = "" + m.reapplyActiveFilter() +} + +// reapplyActiveFilter re-runs whichever filter (search or parametric) is +// currently active against the freshly rebuilt allRows. It keeps the active +// filter in effect after edits, copies, and deletes, which rebuild the table. +// With no active filter, the full row set is shown. +func (m *modelNew) reapplyActiveFilter() { + if m.searchInput.Value() != "" { + m.applySearchFilter(m.searchInput.Value()) + return + } + for _, pi := range m.paramInputs { + if pi.Value() != "" { + m.applyParametricFilter() + return + } + } + m.filteredRows = m.allRows + m.rowToDataIdx = nil + m.table.SetRows(m.allRows) } // getSelectedCSVFile returns the CSVFile for the currently selected file, or nil. From a81e18adbbab14aabdf74331f3f4dfc53843082d Mon Sep 17 00:00:00 2001 From: Cliff Brake Date: Wed, 15 Jul 2026 14:06:11 -0400 Subject: [PATCH 2/3] add roadmap --- roadmap.md | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 roadmap.md diff --git a/roadmap.md b/roadmap.md new file mode 100644 index 0000000..9d0d985 --- /dev/null +++ b/roadmap.md @@ -0,0 +1,2 @@ +- Select symbols and footprints from KiCad libraries +- Show error if symbol/footprint cannot be found From 2fcf7652316a00f0d82e0937fdd1683c3e59604d Mon Sep 17 00:00:00 2001 From: Cliff Brake Date: Wed, 15 Jul 2026 14:06:28 -0400 Subject: [PATCH 3/3] v0.9.2 --- CHANGELOG.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index fe60c9d..8991a4c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -11,6 +11,8 @@ For more details or to discuss releases, please visit the ## [Unreleased] +## [0.9.2] - 2026-07-15 + - TUI: an active search or parametric filter now stays applied after copying, deleting, adding, or editing a part. The list previously reverted to showing every row until the filter was re-entered.