Add Markets sort-by: change to sort by percent change

This commit is contained in:
Eric Haughee
2024-10-03 11:10:34 -07:00
parent 8a8aaa752e
commit e434fe0847
3 changed files with 11 additions and 1 deletions

View File

@@ -38,6 +38,10 @@ func (widget *Markets) Update(ctx context.Context) {
markets.SortByAbsChange()
}
if widget.Sort == "change" {
markets.SortByChange()
}
widget.Markets = markets
}