feat: unified 1..9 words session narrative, dice input before reveal, dedicated results screen, and clean session history grouping

This commit is contained in:
Alma Alexyz
2026-08-31 15:23:59 +05:00
parent bc892c3388
commit 6f9d4d4cca
11 changed files with 1207 additions and 1099 deletions
+8 -8
View File
@@ -87,19 +87,19 @@ class _WordCardWidgetState extends State<WordCardWidget> {
Future<void> _recordToHistory() async {
if (_savedToHistory) return;
final newId = DateTime.now().millisecondsSinceEpoch.toString();
final entry = HistoryEntry(
final sessionWord = SessionWord.fromWordItem(
widget.word,
positionTitle: widget.positionTitle,
);
final session = OracleSession(
id: newId,
timestamp: DateTime.now(),
word: widget.word.word,
sessionNumber: widget.word.sessionNumber,
partOfSpeech: widget.word.partOfSpeech,
symbolicMeaning: widget.word.description,
readingType: widget.positionTitle ?? 'Жребий номера',
positionTitle: widget.positionTitle,
wordsCount: 1,
words: [sessionWord],
question: widget.question,
aiInterpretation: _aiInterpretation,
);
await _repo.addHistoryEntry(entry);
await _repo.saveSession(session);
if (!mounted) return;
setState(() {
_savedToHistory = true;