It was annoying me that the wallet history in the Dashboard exceeded the screen length and I could not scroll down to see the older entries.
This fixes that. Up/Down arrows now work to move a selected row and it scrolls to end of list and back. The impl is surprisingly manual.... I was expecting something like a set scrollable=true property on the widget, but no such luck. Anyway, I based it on a ratatui example.
I originally had it wrapping around as per the example, but it was kind of surprising behavior, so now I made it stop at first entry when scrolling up and last entry when down.
I wanted to add PgUp/PgDn support, but I couldn't find a way to get the number of visible rows in the table given that terminal height is variable.
From a bit of digging on ratatui github I see that there are several issues open about scrolling and they are discussing new design(s), so hopefully the new design will enable easy PgUp/PgDn handling. see: draft PR, rfc.
It was annoying me that the wallet history in the Dashboard exceeded the screen length and I could not scroll down to see the older entries.
This fixes that. Up/Down arrows now work to move a selected row and it scrolls to end of list and back. The impl is surprisingly manual.... I was expecting something like a
set scrollable=true
property on the widget, but no such luck. Anyway, I based it on a ratatui example.I originally had it wrapping around as per the example, but it was kind of surprising behavior, so now I made it stop at first entry when scrolling up and last entry when down.
I wanted to add PgUp/PgDn support, but I couldn't find a way to get the number of visible rows in the table given that terminal height is variable.
From a bit of digging on ratatui github I see that there are several issues open about scrolling and they are discussing new design(s), so hopefully the new design will enable easy PgUp/PgDn handling. see: draft PR, rfc.