Simpl-Resultat/src-tauri
le king fu 0132e6e164
All checks were successful
PR Check / rust (push) Successful in 21m45s
PR Check / frontend (push) Successful in 2m17s
PR Check / rust (pull_request) Successful in 21m1s
PR Check / frontend (pull_request) Successful in 2m13s
feat(categories): add restore backup banner and permanent restore action (#122)
Surfaces the pre-migration SREF backup to the user so they can roll back a
category migration without digging into the filesystem:

- 90-day dismissable banner at the top of Settings > Categories pointing to
  the automatic backup (hidden once reverted, once dismissed, or past 90d).
- Permanent "Restore a backup" entry in Settings > Categories, available as
  long as a migration journal exists (even past the 90-day window).
- Confirmation modal with two-step consent, red Restore button, fallback
  file picker when the recorded path is missing, PIN prompt for encrypted
  SREF files, full-page reload on success.

Internals:
- New `categoryRestoreService` wrapping `read_import_file` +
  `importTransactionsWithCategories` with stable error codes
  (file_missing, read_failed, parse_failed, wrong_envelope_type,
  needs_password, wrong_password, import_failed).
- New `file_exists` Tauri command for the pre-flight presence check.
- On success: `categories_schema_version=v2` + merge `reverted_at` into
  `last_categories_migration`.
- Pure `shouldShowBanner` / `isWithinBannerWindow` helpers with tests.
- FR/EN i18n keys under `settings.categoriesCard.restore*`.
- CHANGELOG entries in both locales.

Closes #122
2026-04-20 21:47:43 -04:00
..
capabilities feat: add Settings page with in-app updater support 2026-02-11 11:47:25 +00:00
icons Initial project scaffold: Tauri v2 + React + TypeScript + TailwindCSS v4 2026-02-07 11:05:11 +00:00
src feat(categories): add restore backup banner and permanent restore action (#122) 2026-04-20 21:47:43 -04:00
.gitignore Initial project scaffold: Tauri v2 + React + TypeScript + TailwindCSS v4 2026-02-07 11:05:11 +00:00
build.rs Initial project scaffold: Tauri v2 + React + TypeScript + TailwindCSS v4 2026-02-07 11:05:11 +00:00
Cargo.lock chore: release v0.8.3 2026-04-19 10:01:29 -04:00
Cargo.toml chore: release v0.8.3 2026-04-19 10:01:29 -04:00
tauri.conf.json chore: release v0.8.3 2026-04-19 10:01:29 -04:00