Skip to content

Update settings screen and its sub-items - #118

Merged
theanmolsharma merged 5 commits into
CypherCommons:masterfrom
chaitika:update-settings
Jul 30, 2026
Merged

Update settings screen and its sub-items#118
theanmolsharma merged 5 commits into
CypherCommons:masterfrom
chaitika:update-settings

Conversation

@chaitika

@chaitika chaitika commented Jun 12, 2026

Copy link
Copy Markdown
Contributor
image image

General, Contact, and Tools sub-screens are empty navigation stubs for now — this PR lands the navigation skeleton, content for each will come in follow-up PRs.

Copilot AI review requested due to automatic review settings June 12, 2026 18:10

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Note

Copilot was unable to run its full agentic suite in this review.

This PR revamps the Settings screen UI into grouped, icon-based rows, adds new Settings subsections (General/Contact/Tools), and extends theming/navigation to support the new design.

Changes:

  • Replaced the simple Settings list with a custom card/row UI, including delete-wallet action and app version display.
  • Added new Settings routes/screens (General, Contact, Tools) and supporting icons.
  • Extended theme tokens and navigation header/back behavior for the updated Settings experience.

Reviewed changes

Copilot reviewed 19 out of 19 changed files in this pull request and generated 6 comments.

Show a summary per file
File Description
screen/settings/Settings.tsx New Settings UI with rows, icons, and delete-wallet flow
screen/settings/GeneralSettings.tsx Adds placeholder General settings screen
screen/settings/ContactBook.tsx Adds placeholder Contact settings screen
screen/settings/ToolsSettings.tsx Adds placeholder Tools settings screen
navigation/DetailViewStackParamList.ts Adds route types for new settings screens
navigation/DetailViewScreensStack.tsx Registers new screens and customizes Settings header
components/navigationStyle.tsx Adds a default custom back button when not first route
components/themes.ts Adds Settings-specific theme color tokens
loc/en.json Adds new Settings strings (titles/subtitles/delete wallet text)
components/icons/*.tsx Adds new icons used by the Settings rows

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread screen/settings/Settings.tsx Outdated
Comment thread screen/settings/Settings.tsx
Comment thread navigation/DetailViewScreensStack.tsx Outdated
Comment thread components/navigationStyle.tsx
Comment thread components/icons/ToolsIcon.tsx Outdated
Comment thread screen/settings/GeneralSettings.tsx
Copilot AI review requested due to automatic review settings July 15, 2026 12:38

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

Copilot AI review requested due to automatic review settings July 15, 2026 13:35

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

Copilot AI review requested due to automatic review settings July 15, 2026 15:08

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

Copilot AI review requested due to automatic review settings July 15, 2026 15:57

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

Copilot AI review requested due to automatic review settings July 15, 2026 17:48

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@chaitika
chaitika marked this pull request as ready for review July 15, 2026 17:49
Copilot AI review requested due to automatic review settings July 16, 2026 15:58

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@notTanveer

Copy link
Copy Markdown
Contributor

feels like there should be a little more gap between the two text (as per the figma design).
image

Copilot AI review requested due to automatic review settings July 19, 2026 08:06

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@chaitika

chaitika commented Jul 19, 2026

Copy link
Copy Markdown
Contributor Author

feels like there should be a little more gap between the two text (as per the figma design).

fixed and folded in 6fcbe05
cc @notTanveer

Copilot AI review requested due to automatic review settings July 22, 2026 14:47

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@notTanveer

Copy link
Copy Markdown
Contributor
image

the top settings header font size doesn't match the figma design.
should be smaller and consistent with the rest of the screens

Copilot AI review requested due to automatic review settings July 23, 2026 10:37

@notTanveer notTanveer left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ACK 013bea5

@notTanveer

Copy link
Copy Markdown
Contributor

one question, why did we extract the delete wallet logic into useDeleteWallet hook?

@chaitika

chaitika commented Jul 25, 2026

Copy link
Copy Markdown
Contributor Author

one question, why did we extract the delete wallet logic into useDeleteWallet hook?

its a good practice to keep views aimed at rendering only, it shouldn't have to carry logic and checks.

Comment thread screen/settings/GeneralSettings.tsx
Comment thread hooks/useDeleteWallet.ts
Comment thread hooks/useDeleteWallet.ts
Comment thread components/navigationStyle.tsx
Comment thread components/navigationStyle.tsx
Comment thread screen/settings/Settings.tsx Outdated
Comment thread screen/settings/Settings.tsx Outdated
Comment thread screen/settings/Settings.tsx
Comment thread screen/settings/Settings.tsx
Comment thread components/themes.ts Outdated
Comment thread screen/settings/Settings.tsx Outdated

const Settings = () => {
const { navigate } = useExtendedNavigation();
interface RowProps {

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Scope note, not a change request for this PR: Row is screen-local, and so are SettingsIconWrapper and the six settings* tokens. Meanwhile every screen these rows navigate to — About.tsx, Currency.tsx, EncryptStorage.tsx, ElectrumSettings.tsx — still uses the old ListItem, so tapping any row drops the user back into the previous visual language. Worth a tracking issue so the split doesn't become permanent.

(Separately: the settings* token prefix is the right call — it matches the existing feature-scoped convention in themes.ts like incomingIconBackground / outgoingIconBorder rather than inventing a new scheme.)

Comment thread screen/settings/Settings.tsx Outdated
Comment thread components/icons/AboutIcon.tsx
Comment thread components/navigationStyle.tsx
Comment thread hooks/useDeleteWallet.ts
Comment thread loc/en.json Outdated
Copilot AI review requested due to automatic review settings July 28, 2026 09:50

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

…-wallet flow

Replaces the plain Settings list with grouped icon-based rows (General,
Currency, Contact, Security, Network, Tools, About), adds stub sub-screens
for General/Contact/Tools, extracts delete-wallet logic into a
useDeleteWallet hook, and wires Settings-specific theme tokens (including
per-icon color tokens) so icon colors go through the theme system instead
of being hardcoded.
Copilot AI review requested due to automatic review settings July 28, 2026 10:02

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

… version methods

The new Settings screen rendered the delete-wallet button unconditionally
while useDeleteWallet silently no-ops when there's no wallet, leaving a
dead button with no feedback. Settings.tsx now hides it via useStorage,
matching the old DeleteWallet.tsx behavior.

Also adds getVersion/getBuildNumber to the react-native-device-info jest
mock, which Settings.tsx now calls at module load for the About row
subtitle; the missing mock methods crashed any test importing Settings.tsx.
Copilot AI review requested due to automatic review settings July 28, 2026 10:37

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

…elete-wallet unit test

navigationStyle.tsx's baseHeaderStyle lacked as const on
headerBackButtonDisplayMode, silently widening it to string and
forcing a load-bearing duplicate assignment in the options literal
to re-narrow the type. Add as const at the source and drop the
duplicate.

Fix inconsistent casing on contact_subtitle ("Silent payment" ->
"Silent Payment").

Add unit coverage for useDeleteWallet's three branches: biometrics
enabled but auth fails, cancel, and success -> navigation reset.
Copilot AI review requested due to automatic review settings July 28, 2026 14:06

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

…eWallet test branches

useDeleteWallet's extraction from DeleteWallet.tsx dropped the
NotificationSuccess haptic that used to fire after a successful deletion;
restore it. Mock DeviceInfo.getPowerState in tests/setup.js since the
haptic call reads it before triggering.

Add coverage for the two untested branches: biometrics enabled and
succeeding, and handleWalletDeletion resolving false.
Copilot AI review requested due to automatic review settings July 28, 2026 14:55

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

Copilot AI review requested due to automatic review settings July 29, 2026 09:20

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

The stub screens render a bare SafeAreaScrollView, so tapping these
rows led to an empty white screen. Drop the rows and their
Stack.Screen registrations until each screen has real content; the
stub files stay for the PR that wires each one back in.
Copilot AI review requested due to automatic review settings July 29, 2026 18:47

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@chaitika
chaitika requested a review from theanmolsharma July 30, 2026 08:01
@theanmolsharma
theanmolsharma merged commit 26d33c2 into CypherCommons:master Jul 30, 2026
4 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.

4 participants