Closed dnalor closed 1 year ago
There may be a bit of a misunderstanding for part of this. The functions you're calling on the table don't modify the underlying table. In fact, none of the exported functions mutate the underlying object, or at least they shouldn't. You need to keep doing what you started doing with the filter input:
m.archTable = m.archTable.WithFilterInputValue( m.currentFilter)
m.archTable = m.archTable.Focused( true)
m.archTable = m.archTable.WithCurrentPage(1)
Or:
m.archTable = m.archTable.WithFilterInputValue(m.currentFilter).Focused(true).WithCurrentPage(1)
That being said, I'm able to reproduce the bug where the table becomes empty while applying the filter via WithFilterInputValue
, so let me fix that.
Released https://github.com/Evertras/bubble-table/releases/tag/v0.15.0 , please let me know if this fixes the issue for you.
Yes, this fixes it. Thanks!
When filtering a table while on a page which doesn't exist anymore after the filter is applied, an empty table is displayed. Programatically scolling to the first page has no effect. After a cursor movement, the newly filtered table is displayed correcty. Example: