diff --git a/src/screens/Sources.tsx b/src/screens/Sources.tsx index 8dc61ee9..f474d862 100644 --- a/src/screens/Sources.tsx +++ b/src/screens/Sources.tsx @@ -38,7 +38,9 @@ function sourceToLangList(sources: Pick[]) { return [...result].sort(langSortCmp); } -function groupByLang>(sources: Source[]): Record { +function groupByLang>( + sources: Source[], +): Record { const result: Record = {}; sources.forEach((source) => { @@ -49,6 +51,8 @@ function groupByLang>(sources: So result[lang].push(source); }); + Object.values(result).forEach((langSources) => langSources.sort((a, b) => a.name.localeCompare(b.name))); + return result; }