mirror of
https://github.com/omnivore-app/omnivore.git
synced 2026-03-11 08:54:26 +00:00
Merge pull request #2161 from omnivore-app/feature/sort-by-wordCount
add sorting by wordsCount
This commit is contained in:
commit
31d04a59e1
1 changed files with 6 additions and 0 deletions
|
|
@ -68,6 +68,7 @@ export enum SortBy {
|
|||
PUBLISHED = 'publishedAt',
|
||||
READ = 'readAt',
|
||||
LISTENED = 'listenedAt',
|
||||
WORDS_COUNT = 'wordsCount',
|
||||
}
|
||||
|
||||
export enum SortOrder {
|
||||
|
|
@ -202,6 +203,11 @@ const parseSortParams = (str?: string): SortParams | undefined => {
|
|||
by: SortBy.READ,
|
||||
order: sortOrder,
|
||||
}
|
||||
case 'WORDSCOUNT':
|
||||
return {
|
||||
by: SortBy.WORDS_COUNT,
|
||||
order: sortOrder,
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue