feat(backup): add automatic weekly encrypted backups
A silent safety net against in-app data loss or DB corruption, with zero friction. Driven off the app lifecycle (startup + when hidden), it writes a sealed .tanemaki copy into the app's private storage once a week, keeping the newest 3 (rotating). Reuses the manual backup's encryption via the extracted ExportImportService.buildSealedBackup(); never throws, so a failed copy can't crash startup or backgrounding. Not registered on web (no file storage). Settings shows a quiet reassurance line with the date of the last automatic copy (localised via intl), hidden where no automatic backup exists.
This commit is contained in:
parent
0e7eb22c26
commit
39adc423b9
19 changed files with 559 additions and 29 deletions
|
|
@ -166,6 +166,9 @@ class _Translations$backup$es extends Translations$backup$en {
|
|||
|
||||
// Translations
|
||||
@override String get title => 'Copia de seguridad';
|
||||
@override String get autoBackupTitle => 'Copias automáticas';
|
||||
@override String autoBackupLast({required Object date}) => 'Última copia guardada el ${date}';
|
||||
@override String get autoBackupNone => 'Se guarda una copia automáticamente en segundo plano';
|
||||
@override String get exportJson => 'Guardar una copia de seguridad';
|
||||
@override String get exportJsonSubtitle => 'Una copia completa para guardar a salvo, restaurar luego o pasar a otro dispositivo';
|
||||
@override String get importJson => 'Restaurar una copia';
|
||||
|
|
@ -994,6 +997,9 @@ extension on TranslationsEs {
|
|||
'settings.aboutText' => 'Inventario local y cifrado para semillas tradicionales. AGPL-3.0.',
|
||||
'settings.aboutOpen' => 'Acerca de Tanemaki',
|
||||
'backup.title' => 'Copia de seguridad',
|
||||
'backup.autoBackupTitle' => 'Copias automáticas',
|
||||
'backup.autoBackupLast' => ({required Object date}) => 'Última copia guardada el ${date}',
|
||||
'backup.autoBackupNone' => 'Se guarda una copia automáticamente en segundo plano',
|
||||
'backup.exportJson' => 'Guardar una copia de seguridad',
|
||||
'backup.exportJsonSubtitle' => 'Una copia completa para guardar a salvo, restaurar luego o pasar a otro dispositivo',
|
||||
'backup.importJson' => 'Restaurar una copia',
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue