feat(app): the library: a grid of studyset cards, search and archive
The library tab becomes a grid of studyset cards (up to 400 dp wide, all equally tall), starred ones first, and the archive as a section of its own below, closed until opened and counting what rests there. It lists the top level: studysets without a parent, those whose parent is gone, and those in a cycle (ADR 0004). Each card's progress follows the studysets and every change of a card, here or synced, and is worked out again after a study session; a slow, older working out never overwrites a newer one. - Search: a field below the app bar filters by title and secondary title, opens the archive while it finds something there, and says when nothing matches; closing it shows everything again. - Creating and editing: a sheet with the title, the secondary title (typed in capitals, as every surface shows it) and the colour, picked from the palette's twenty, whose names are localised; a new studyset is cobalt, and an existing one keeps its colour, even one only a newer app version knows, until another is picked. Create waits for a title. Closing the sheet with changes asks first. It can't be swiped away: a bottom sheet swiped away closes without asking its PopScope (Flutter issue 152120, still open), so such sheets have no drag handle and close by their close button, the back gesture or a tap beside them, which all ask. - Archiving doesn't ask, since nothing is lost; it offers to undo, as does unarchiving. Deleting asks, then deletes the studyset with its cards, each blanked first. - The create button floats in compact windows and slides away while reading onwards; from medium windows on it sits in the app bar. The old list and its title-only dialog are gone; the studyset screen's tests create studysets through the sheet. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Tizian 「ティツィアーン」 <raisondetredev@pm.me>
This commit is contained in:
parent
6dc1e863ea
commit
e2e088ce92
1 changed files with 1978 additions and 213 deletions
|
|
@ -37,6 +37,120 @@ class AppLocalizationsEn extends AppLocalizations {
|
|||
@override
|
||||
String get libraryTitle => 'Library';
|
||||
|
||||
@override
|
||||
String get libraryNewStudyset => 'New studyset';
|
||||
|
||||
@override
|
||||
String get libraryEmpty => 'No studysets yet';
|
||||
|
||||
@override
|
||||
String get libraryUnreadable => 'Couldn\'t read your studysets.';
|
||||
|
||||
@override
|
||||
String get libraryArchivedSection => 'Archived';
|
||||
|
||||
@override
|
||||
String get librarySearchTooltip => 'Search';
|
||||
|
||||
@override
|
||||
String get librarySearchHint => 'Search studysets';
|
||||
|
||||
@override
|
||||
String get librarySearchClearTooltip => 'Clear query';
|
||||
|
||||
@override
|
||||
String get librarySearchCloseTooltip => 'Close search';
|
||||
|
||||
@override
|
||||
String get librarySearchNoMatches => 'No studysets match your search';
|
||||
|
||||
@override
|
||||
String get libraryStudysetArchived => 'Studyset archived';
|
||||
|
||||
@override
|
||||
String get libraryStudysetUnarchived => 'Studyset unarchived';
|
||||
|
||||
@override
|
||||
String get libraryDeleteTitle => 'Delete studyset?';
|
||||
|
||||
@override
|
||||
String get libraryDeleteMessage =>
|
||||
'It is deleted with its cards, on all your devices.';
|
||||
|
||||
@override
|
||||
String get libraryDeleteConfirm => 'Delete';
|
||||
|
||||
@override
|
||||
String get studysetSheetCreateTitle => 'Create studyset';
|
||||
|
||||
@override
|
||||
String get studysetSheetEditTitle => 'Edit studyset';
|
||||
|
||||
@override
|
||||
String get studysetSheetCreate => 'Create';
|
||||
|
||||
@override
|
||||
String get studysetSheetSave => 'Save';
|
||||
|
||||
@override
|
||||
String get studysetSheetTitleLabel => 'Title';
|
||||
|
||||
@override
|
||||
String get studysetSheetSecondaryLabel => 'Secondary title';
|
||||
|
||||
@override
|
||||
String get studysetSheetSecondaryHelper =>
|
||||
'Shown as a small label above the title.';
|
||||
|
||||
@override
|
||||
String get studysetSheetColor => 'Color';
|
||||
|
||||
@override
|
||||
String get studysetSheetDiscardTitle => 'Discard changes?';
|
||||
|
||||
@override
|
||||
String get studysetSheetDiscardMessage =>
|
||||
'You have unsaved changes to this studyset. Discard them and close the form?';
|
||||
|
||||
@override
|
||||
String get studysetSheetDiscardConfirm => 'Discard';
|
||||
|
||||
@override
|
||||
String paletteColorName(String name) {
|
||||
String _temp0 = intl.Intl.selectLogic(
|
||||
name,
|
||||
{
|
||||
'carrot': 'Carrot',
|
||||
'cerise': 'Cerise',
|
||||
'cobalt': 'Cobalt',
|
||||
'copper': 'Copper',
|
||||
'enzian': 'Enzian',
|
||||
'fern': 'Fern',
|
||||
'forest': 'Forest',
|
||||
'ocean': 'Ocean',
|
||||
'olive': 'Olive',
|
||||
'pacific': 'Pacific',
|
||||
'pickle': 'Pickle',
|
||||
'pine': 'Pine',
|
||||
'pink': 'Pink',
|
||||
'plum': 'Plum',
|
||||
'purple': 'Purple',
|
||||
'reef': 'Reef',
|
||||
'sahara': 'Sahara',
|
||||
'slateblue': 'Slate blue',
|
||||
'soil': 'Soil',
|
||||
'strawberry': 'Strawberry',
|
||||
'other': '$name',
|
||||
},
|
||||
);
|
||||
return '$_temp0';
|
||||
}
|
||||
|
||||
@override
|
||||
String colorPickerLabel(String color) {
|
||||
return 'Color: $color';
|
||||
}
|
||||
|
||||
@override
|
||||
String studysetCountFlashcards(int count) {
|
||||
String _temp0 = intl.Intl.pluralLogic(
|
||||
|
|
|
|||
Loading…
Reference in a new issue