mirror of
https://github.com/chenasraf/pantry-flutter.git
synced 2026-05-17 17:28:03 +00:00
feat: add sorting by category for checklist
This commit is contained in:
@@ -661,6 +661,11 @@ class SortChecklistsMessages {
|
||||
/// ```
|
||||
String get nameZA => """Name Z–A""";
|
||||
|
||||
/// ```dart
|
||||
/// "By category"
|
||||
/// ```
|
||||
String get category => """By category""";
|
||||
|
||||
/// ```dart
|
||||
/// "Custom"
|
||||
/// ```
|
||||
@@ -1231,6 +1236,7 @@ Please complete login in your browser.""",
|
||||
"""checklists.sort.oldestFirst""": """Oldest first""",
|
||||
"""checklists.sort.nameAZ""": """Name A–Z""",
|
||||
"""checklists.sort.nameZA""": """Name Z–A""",
|
||||
"""checklists.sort.category""": """By category""",
|
||||
"""checklists.sort.custom""": """Custom""",
|
||||
"""notesWall.noNotes""": """No notes yet.""",
|
||||
"""notesWall.failedToLoad""": """Failed to load notes.""",
|
||||
|
||||
@@ -120,6 +120,7 @@ checklists:
|
||||
oldestFirst: Oldest first
|
||||
nameAZ: "Name A\u2013Z"
|
||||
nameZA: "Name Z\u2013A"
|
||||
category: By category
|
||||
custom: Custom
|
||||
|
||||
notesWall:
|
||||
|
||||
@@ -17,6 +17,7 @@ class ChecklistSortButton extends StatelessWidget {
|
||||
'oldest',
|
||||
'name_asc',
|
||||
'name_desc',
|
||||
'category',
|
||||
'custom',
|
||||
];
|
||||
|
||||
@@ -25,6 +26,7 @@ class ChecklistSortButton extends StatelessWidget {
|
||||
'oldest' => m.checklists.sort.oldestFirst,
|
||||
'name_asc' => m.checklists.sort.nameAZ,
|
||||
'name_desc' => m.checklists.sort.nameZA,
|
||||
'category' => m.checklists.sort.category,
|
||||
'custom' => m.checklists.sort.custom,
|
||||
_ => key,
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user