A fully open source & end-to-end encrypted note taking alternative to Evernote.
TypeScript asp-net-coredotnet-coreelectronfosshacktoberfestnote-managmentnote-takingnote-taking-appnotebooknotesnotes-appopen-sourceopensourceprivacyproductivityreactreact-nativereactjsself-hosted
fix: do not allow sort by title when groupBy === default
thecodrr36353a4b0c01
diff --git a/packages/core/utils/grouping.js b/packages/core/utils/grouping.jsindex 106c065f2..c92339873 100644--- a/packages/core/utils/grouping.js+++ b/packages/core/utils/grouping.js@@ -28,12 +28,14 @@ const KEY_SELECTORS = {month: (item, groupBy) => months[new Date(item[groupBy]).getMonth()],week: (item, groupBy) => getWeekGroupFromTimestamp(item[groupBy]),year: (item, groupBy) => new Date(item[groupBy]).getFullYear().toString(),- default: (item, groupBy) =>- item[groupBy] >= TIMESTAMPS.recent()+ default: (item, groupBy) => {+ if (groupBy === "title") groupBy = "dateEdited";+ return item[groupBy] >= TIMESTAMPS.recent()? "Recent": item[groupBy] >= TIMESTAMPS.lastWeek()? "Last week"- : "Older",+ : "Older";+ },};/**