Skip to content

Complete the post-creation wallet backup reminder#288

Merged
El-swaggerito merged 1 commit into
Axionvera:mainfrom
Adeolu01:feat/wallet-backup-reminder-256
Jul 23, 2026
Merged

Complete the post-creation wallet backup reminder#288
El-swaggerito merged 1 commit into
Axionvera:mainfrom
Adeolu01:feat/wallet-backup-reminder-256

Conversation

@Adeolu01

Copy link
Copy Markdown
Contributor

closes #256

Summary

The backup reminder shown after wallet creation existed but was only partly finished: it rendered from the hardcoded dark palette, exposed no accessibility semantics, was not part of the components barrel, had no test coverage, and was undocumented. This PR completes it against the issue's acceptance criteria.

What changed

src/components/BackupReminderModal.tsx

  • Renders with the resolved theme palette (useTheme) instead of the hardcoded COLORS constants, so the reminder no longer appears as a dark card over a light-theme Home screen. The warning box now uses surfaceLight / border rather than fixed white alpha values that were invisible on light surfaces.
  • The confirmation checkbox resets when the reminder closes. The reminder's pending flag is persisted, so an unacknowledged reminder reappears on the next launch; without the reset it would have come back already ticked.
  • Accessibility: the confirmation is exposed as an accessibilityRole="checkbox" with a label and a live checked state, the title carries a header role, and the overlay is marked accessibilityViewIsModal so assistive tech does not read the Home screen behind it.
  • The card scrolls instead of clipping at large font scales.
  • Documents why the modal is deliberately non-dismissable and why it renders no key material.

Other

  • Exported BackupReminderModal from src/components/index.ts.
  • Documented the reminder step, its persistence behaviour, and its expected states in the create-wallet flow in docs/user-flows.md.
  • Added __tests__/BackupReminderModal.test.tsx.

Acceptance criteria

  • Backup reminder is shown — rendered over Home after creation, driven by the persisted showBackupReminder flag.
  • Copy explains responsibility — the key is the only route back into the wallet, PocketPay holds no copy, and it must never be shared. Covered by test.
  • No secrets are exposed unnecessarily — the reminder renders no key material; the secret key is revealed only on the creation screen, behind an explicit reveal. Covered by test.
  • Users can acknowledge reminder — the acknowledge action stays disabled until the confirmation is checked, then persists the acknowledgement. Covered by test.
  • Flow remains simple — one modal, one checkbox, one action; no new screens or navigation.

Testing

npx jest __tests__/BackupReminderModal.test.tsx

5 tests, all passing: copy and absence of key material, the disabled-until-confirmed action, the accessible checkbox state, the reset on reopen, and that nothing renders while hidden.

The repository has pre-existing failures on main in send, paymentSuccess, home.pullToRefresh, WalletResetConfirmModal, and vault. This branch does not change any of them.

Notes

No behavioural change to walletStore; the persistence and re-show logic it already had is unchanged, now documented and covered.

Make the backup reminder shown after wallet creation theme-aware,
accessible, and covered by tests.

- Render the reminder with the resolved theme palette instead of the
  hardcoded dark constants, so it matches the rest of the app in light
  mode.
- Reset the confirmation checkbox when the reminder closes, so a
  reminder that reappears after an unacknowledged session starts
  unchecked.
- Expose the confirmation as an accessible checkbox with a label and
  checked state, mark the overlay as a modal view, and add a header
  role to the title.
- Allow the card to scroll at large font scales instead of clipping.
- Export the component from the components barrel.
- Document the reminder step in the create-wallet user flow.

No key material is rendered by the reminder; the secret key stays
behind the explicit reveal on the creation screen.
@El-swaggerito
El-swaggerito merged commit f102316 into Axionvera:main Jul 23, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add wallet backup reminder after creation

2 participants