feat(list): add IsFiltered method (#98)

This commit is contained in:
Jonah
2022-07-05 20:38:10 +00:00
committed by GitHub
parent 3a34fc4ff8
commit b74f696cc8

View File

@@ -534,6 +534,15 @@ func (m Model) SettingFilter() bool {
return m.filterState == Filtering
}
// IsFiltered returns whether or not the list is currently filtered.
// It's purely a convenience method for the following:
//
// m.FilterState() == FilterApplied
//
func (m Model) IsFiltered() bool {
return m.filterState == FilterApplied
}
// Width returns the current width setting.
func (m Model) Width() int {
return m.width