feat(import): implement recipe import functionality with file and URL support

Co-authored-by: Copilot <copilot@github.com>
This commit is contained in:
Nils-Johan Gynther
2026-04-22 21:31:25 +02:00
parent 8ebf119d39
commit 81117fbcb7
11 changed files with 617 additions and 13 deletions
@@ -0,0 +1,19 @@
/// Result from `POST /api/quick-import`.
class QuickImportResult {
final String markdown;
final String source; // 'ica' | 'pdf' | 'image' | 'other'
final String? imageUrl;
const QuickImportResult({
required this.markdown,
required this.source,
this.imageUrl,
});
factory QuickImportResult.fromJson(Map<String, dynamic> json) =>
QuickImportResult(
markdown: json['markdown'] as String? ?? '',
source: json['source'] as String? ?? 'other',
imageUrl: json['imageUrl'] as String?,
);
}