Skip to content

fix: correct dark theme colors in encrypted vault delete confirmation dialog - #2260

Merged
ethicnology merged 1 commit into
developfrom
2257-theme-delete-confirmation-dialog-is-unreadable-in-dark-theme-for-encrypted-vaults-in-google-drive
Jun 11, 2026
Merged

fix: correct dark theme colors in encrypted vault delete confirmation dialog#2260
ethicnology merged 1 commit into
developfrom
2257-theme-delete-confirmation-dialog-is-unreadable-in-dark-theme-for-encrypted-vaults-in-google-drive

Conversation

@wired-pasteque

Copy link
Copy Markdown
Collaborator

Fix: #2257

Simulator Screenshot - iPhone 16e - 2026-06-08 at 15 05 08 Simulator Screenshot - iPhone 16e - 2026-06-08 at 15 05 13

@claude

claude Bot commented Jun 8, 2026

Copy link
Copy Markdown

Claude finished @wired-pasteque's task in 1m 32s —— View job


Review: dark theme fix for delete confirmation dialog

  • Gather context (diff, file)
  • Analyze color/theme changes
  • Check for regressions in both bottom sheets
  • Post review findings

Verdict: looks correct ✅ — the fix resolves #2257 and I found no correctness, security, or regression issues.

Why the fix is right

The root cause is a token mismatch. Bottom-sheet text (BBText / context.font.*) inherits the ambient theme text color, which is light in dark mode. The old background token resolved to white in both themes, so light text on a white sheet was invisible:

token light dark
onPrimary (old bg) #FFFFFF #FFFFFF ❌ light text on white
onSecondary (new bg) #FFFFFF #15171C ✅ light text on near-black

Switching the container background to context.appColors.onSecondary (drive_vaults_list_page.dart:99 and :148) gives a dark sheet in dark mode while preserving the white sheet in light mode, so the title/confirmation text and buttons are readable in both. The button contrast also holds up:

  • Cancel/Export: bgColor: secondary / textColor: onSecondary — inverts cleanly against the new background in both themes.
  • Delete: bgColor: primary (red) / textColor: onPrimary (white) — unaffected, readable in both.

Applying the same change to both sheets (_showActionsBottomSheet and _showDeleteConfirmationBottomSheet) is the right call — the actions sheet had the same latent dark-theme issue.

The remaining diff (Radius.circular(32)12, and the large reformat block) is cosmetic / dart format output with no functional impact.

Minor (non-blocking) nit

Using onSecondary as a container background is a little unconventional — onX tokens are semantically intended for foreground content drawn on X. It works here only because its values happen to be surface-appropriate (white / near-black). A token like surface / surfaceContainer would read more idiomatically for a sheet background, but the current choice yields the intended high contrast against the secondary-colored buttons, so it's a defensible deliberate choice rather than a bug. Worth a quick design sanity-check that #15171C (vs surface #1C1C1E) is the intended sheet shade.

Note: I reviewed by reading the diff and theme palette (lib/core/themes/colors.dart); I did not run flutter analyze in this environment. Changes are value swaps + formatting only, so analyzer risk is low.

@ethicnology

Copy link
Copy Markdown
Member

@thibistaken and @i5hi should we make this part of #2258 ?

@ethicnology
ethicnology merged commit 926f4df into develop Jun 11, 2026
2 checks 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.

Delete confirmation dialog is unreadable in dark theme for encrypted vaults in Google Drive

2 participants