feat: navigation store feat: implement OPDS entry caching system Add comprehensive caching for OPDS publications with local image storage and Dublin Core Terms metadata extraction. This enables offline viewing, fixes Library screen to show book titles and covers, and improves overall UX. - Add publications table with full metadata (title, authors, series, publisher, ISBN, language) - Implement local image cache service for covers and thumbnails - Extract DCTerms metadata (series, publisher, language, ISBN) from OPDS feeds - Link reading progress to cached publications - Update Library screen to display cached publication data and covers - Cache publications automatically when starting to read - Fix navigation stack issues by using context.push() instead of context.go() - Add explicit back button to EPUB reader with proper PopScope handling - Implement UNIQUE constraint on reading_progress to prevent duplicates - Save reading progress on screen dispose for both EPUB and image readers Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
78 lines
3.1 KiB
Dart
78 lines
3.1 KiB
Dart
// GENERATED CODE - DO NOT MODIFY BY HAND
|
|
|
|
part of 'publication.dart';
|
|
|
|
// **************************************************************************
|
|
// JsonSerializableGenerator
|
|
// **************************************************************************
|
|
|
|
_$PublicationImpl _$$PublicationImplFromJson(Map<String, dynamic> json) =>
|
|
_$PublicationImpl(
|
|
id: json['id'] as String,
|
|
serverId: json['serverId'] as String,
|
|
opdsId: json['opdsId'] as String,
|
|
title: json['title'] as String,
|
|
authors: (json['authors'] as List<dynamic>?)
|
|
?.map((e) => e as String)
|
|
.toList() ??
|
|
const [],
|
|
summary: json['summary'] as String?,
|
|
content: json['content'] as String?,
|
|
coverPath: json['coverPath'] as String?,
|
|
thumbnailPath: json['thumbnailPath'] as String?,
|
|
coverUrl: json['coverUrl'] as String?,
|
|
thumbnailUrl: json['thumbnailUrl'] as String?,
|
|
series: json['series'] as String?,
|
|
seriesPosition: (json['seriesPosition'] as num?)?.toDouble(),
|
|
publisher: json['publisher'] as String?,
|
|
language: json['language'] as String?,
|
|
isbn: json['isbn'] as String?,
|
|
categories: (json['categories'] as List<dynamic>?)
|
|
?.map((e) => e as String)
|
|
.toList() ??
|
|
const [],
|
|
links: (json['links'] as List<dynamic>?)
|
|
?.map((e) => OPDSLink.fromJson(e as Map<String, dynamic>))
|
|
.toList() ??
|
|
const [],
|
|
streamLink: json['streamLink'] == null
|
|
? null
|
|
: OPDSStreamLink.fromJson(json['streamLink'] as Map<String, dynamic>),
|
|
published: json['published'] == null
|
|
? null
|
|
: DateTime.parse(json['published'] as String),
|
|
updated: json['updated'] == null
|
|
? null
|
|
: DateTime.parse(json['updated'] as String),
|
|
firstCachedAt: DateTime.parse(json['firstCachedAt'] as String),
|
|
lastCachedAt: DateTime.parse(json['lastCachedAt'] as String),
|
|
lastAccessedAt: DateTime.parse(json['lastAccessedAt'] as String),
|
|
);
|
|
|
|
Map<String, dynamic> _$$PublicationImplToJson(_$PublicationImpl instance) =>
|
|
<String, dynamic>{
|
|
'id': instance.id,
|
|
'serverId': instance.serverId,
|
|
'opdsId': instance.opdsId,
|
|
'title': instance.title,
|
|
'authors': instance.authors,
|
|
'summary': instance.summary,
|
|
'content': instance.content,
|
|
'coverPath': instance.coverPath,
|
|
'thumbnailPath': instance.thumbnailPath,
|
|
'coverUrl': instance.coverUrl,
|
|
'thumbnailUrl': instance.thumbnailUrl,
|
|
'series': instance.series,
|
|
'seriesPosition': instance.seriesPosition,
|
|
'publisher': instance.publisher,
|
|
'language': instance.language,
|
|
'isbn': instance.isbn,
|
|
'categories': instance.categories,
|
|
'links': instance.links,
|
|
'streamLink': instance.streamLink,
|
|
'published': instance.published?.toIso8601String(),
|
|
'updated': instance.updated?.toIso8601String(),
|
|
'firstCachedAt': instance.firstCachedAt.toIso8601String(),
|
|
'lastCachedAt': instance.lastCachedAt.toIso8601String(),
|
|
'lastAccessedAt': instance.lastAccessedAt.toIso8601String(),
|
|
};
|