aboutsummaryrefslogtreecommitdiff
path: root/viewer/src/services
diff options
context:
space:
mode:
Diffstat (limited to 'viewer/src/services')
-rw-r--r--viewer/src/services/itemComparators.ts (renamed from viewer/src/services/itemSortFn.ts)4
1 files changed, 3 insertions, 1 deletions
diff --git a/viewer/src/services/itemSortFn.ts b/viewer/src/services/itemComparators.ts
index a7e0883..c8fedbe 100644
--- a/viewer/src/services/itemSortFn.ts
+++ b/viewer/src/services/itemComparators.ts
@@ -17,7 +17,9 @@
17-- along with this program. If not, see <https://www.gnu.org/licenses/>. 17-- along with this program. If not, see <https://www.gnu.org/licenses/>.
18*/ 18*/
19 19
20export default class ItemSortFn { 20export type ItemComparator = (left: Gallery.Item, right: Gallery.Item) => number;
21
22export default class ItemComparators {
21 static sortByNameAsc(left: Gallery.Item, right: Gallery.Item): number { 23 static sortByNameAsc(left: Gallery.Item, right: Gallery.Item): number {
22 return left.title.localeCompare(right.title); 24 return left.title.localeCompare(right.title);
23 } 25 }