Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

frontend: always show manage-device in settings menu #3199

Conversation

thisconnect
Copy link
Collaborator

Conditionally hiding navigation items is not ideal and can be confusing.

Another reason to always show 'Manage device' but with 'No device connected' is to have a place to add detect-bitbox button.

With this change the app will route into device settings if the user unlocks on no-connected-device route.

It does not cover showing no-connected-device again after the user unplugs, reason is that with rememeber-wallets this should go to account-summary and without go to waiting for device. There was no clean way to detect and route back to no-connected-device.

Ideally the 'Manage accounts' item is also always shown in settings navigation, which can be done in another commit.

Before asking for reviews, here is a check list of the most common things you might need to consider:

  • updating the Changelog
  • writing unit tests
  • checking if your changes affect other coins or tokens in unintended ways
  • testing on multiple environments (Qt, Android, ...)
  • having an AI review your changes

@thisconnect thisconnect force-pushed the frontend-always-show-device-settings branch 2 times, most recently from 33a9378 to acd7cbe Compare February 26, 2025 12:37
@thisconnect thisconnect requested a review from benma February 26, 2025 13:00
Copy link
Contributor

@benma benma left a comment

Choose a reason for hiding this comment

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

utACK

import { ManageDeviceGuide } from './bitbox02/settings-guide';
import styles from './no-device-connected.module.css';

type TProps = {
Copy link
Contributor

Choose a reason for hiding this comment

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

use TPagePropsWithSettingsTabs?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

good catch thanks

Conditionally hiding navigation items is not ideal and can be
confusing.

Another reason to always show 'Manage device' but with 'No device
connected' is to have a place to add detect-bitbox button.

With this change the app will route into device settings if the
user unlocks on no-connected-device route.

It does not cover showing no-connected-device again after the user
unplugs, reason is that with rememeber-wallets this should go to
account-summary and without go to waiting for device. There was
no clean way to detect and route back to no-connected-device.

Ideally the 'Manage accounts' item is also always shown in settings
navigation, which can be done in another commit.
Ensure the "Manage Accounts" navigation item is always visible,
even when no accounts are present. Consistently displaying navigation
items improves usability and prevents confusion caused by conditional
visibility.
@thisconnect thisconnect force-pushed the frontend-always-show-device-settings branch from 43d7f5b to a9f8348 Compare February 26, 2025 13:10
@thisconnect thisconnect merged commit 09160d6 into BitBoxSwiss:master Feb 26, 2025
10 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.

2 participants