feat(app): cite sources in APA, MLA or Chicago, and give studysets a bibliography

A source is now shared by learning paths and studysets (core/citation/):
authors as full names, year, title, what it is a part of, publisher,
ISBN, link, and a citation kept as a file brought it. formatCitation
cites it in APA 7, MLA 9 or Chicago 18: it inverts and abbreviates
names itself (particles, suffixes, names written as already cited stay),
sets a work of its own in italics and a part of something apart from
the whole, and writes a missing year as "n.d." in APA and Chicago.

- Settings: a Citations card per device, with a preview and a link to
  the style's own guide.
- Studysets: a Bibliography button opens the works cited, to read and,
  behind its pencil, to change (studyset schema 4).
- Steps: sources edited through the same sheet, opened from an
  "N sources" button in the runner (step schema 2; schema 1 reads on).
- Path import: steps' sources, text kept as written, the old format's
  "citation" read as what a source is part of.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Tizian 「ティツィアーン」 <raisondetredev@pm.me>
This commit is contained in:
Tizian 「ティツィアーン」 2026-10-07 17:07:04 +02:00
commit 65976ae63a
Signed by: raisondetredev
GPG key ID: 07F6FCF405488B64

View file

@ -193,6 +193,13 @@ class AppLocalizationsEn extends AppLocalizations {
@override
String get studysetOptions => 'Options';
@override
String get studysetBibliography => 'Bibliography';
@override
String get studysetBibliographyIntro =>
'Works cited across this studyset, in the citation style chosen in Settings.';
@override
String get studysetMenuEdit => 'Edit';
@ -454,28 +461,10 @@ class AppLocalizationsEn extends AppLocalizations {
String get stepFeedbackNone => 'None';
@override
String get stepSources => 'Sources';
String get sources => 'Sources';
@override
String get stepAddSource => 'Add source';
@override
String get stepRemoveSource => 'Remove source';
@override
String get stepSourceAuthors => 'Authors';
@override
String get stepSourceYear => 'Year';
@override
String get stepSourceTitle => 'Title';
@override
String get stepSourceUrl => 'Link';
@override
String stepSourcesCount(int count) {
String sourcesCount(int count) {
String _temp0 = intl.Intl.pluralLogic(
count,
locale: localeName,
@ -485,6 +474,104 @@ class AppLocalizationsEn extends AppLocalizations {
return '$_temp0';
}
@override
String get sourcesNone => 'No sources cited yet.';
@override
String get sourcesEdit => 'Edit sources';
@override
String get sourcesEditDone => 'Done editing';
@override
String get sourceAdd => 'Add a source';
@override
String get sourceEdit => 'Edit source';
@override
String get sourceRemove => 'Remove source';
@override
String get sourceRemoved => 'Source removed';
@override
String get sourceSheetAdd => 'Add';
@override
String get sourceAuthors => 'Authors';
@override
String get sourceAuthorsHint =>
'Full names, one per line, e.g. Mark A. McDaniel';
@override
String get sourceYear => 'Year';
@override
String get sourceYearHint => 'e.g. 2014';
@override
String get sourceTitle => 'Title';
@override
String get sourceTitleHint => 'Title of the work';
@override
String get sourceContainer => 'Published in';
@override
String get sourceContainerHint =>
'Journal, book or website it is part of, with pages';
@override
String get sourceContainerHelper =>
'Leave empty for a work of its own, such as a book.';
@override
String get sourcePublisher => 'Publisher';
@override
String get sourcePublisherHint => 'e.g. Belknap Press';
@override
String get sourceIsbn => 'ISBN';
@override
String get sourceIsbnHint => 'e.g. 978-0-674-72901-8';
@override
String get sourceUrl => 'Link';
@override
String get sourceUrlHint => 'https://…';
@override
String sourceImportedAs(String citation) {
return 'Imported as: $citation';
}
@override
String sourceIsbnLine(String isbn) {
return 'ISBN: $isbn';
}
@override
String get sourceAvailableAt => 'Available at:';
@override
String get sourceEmpty => 'Empty reference';
@override
String get sourceDiscardTitle => 'Discard changes?';
@override
String get sourceDiscardMessage =>
'What you typed for this source will be lost.';
@override
String get sourceDiscardConfirm => 'Discard';
@override
String get stepConflict =>
'This step was changed differently on another device. Keep one version to go on writing.';
@ -890,6 +977,31 @@ class AppLocalizationsEn extends AppLocalizations {
@override
String get settingsLanguageDevice => 'Device language';
@override
String get settingsCitations => 'Citations';
@override
String get settingsCitationsDescription =>
'How sources and studysets\' bibliographies are cited on this device. Type authors\' full names: each style abbreviates and orders them itself.';
@override
String get settingsCitationStyle => 'Style';
@override
String get settingsCitationStyleApa => 'APA (7th edition)';
@override
String get settingsCitationStyleMla => 'MLA (9th edition)';
@override
String get settingsCitationStyleChicago => 'Chicago (18th edition)';
@override
String get settingsCitationPreview => 'Preview';
@override
String get settingsCitationGuide => 'Official guide';
@override
String settingsVersion(String version, String build) {
return 'Version $version (build $build)';
@ -3091,6 +3203,10 @@ class AppLocalizationsEn extends AppLocalizations {
@override
String get pathImportTitleNotText => 'a title must be text.';
@override
String get pathImportMalformedSource =>
'a source must be an object or text, and its parts text.';
@override
String get pomodoroTopBarHint =>
'The timer can count down in GNOME\'s top bar, with its buttons, once the AppIndicator extension is on.';