Skip to content

Fixed the sidebar navigation issue.#162

Open
coderranger2 wants to merge 1 commit into
GDSC-RCCIIT:mainfrom
coderranger2:srija/sidebarquery
Open

Fixed the sidebar navigation issue.#162
coderranger2 wants to merge 1 commit into
GDSC-RCCIIT:mainfrom
coderranger2:srija/sidebarquery

Conversation

@coderranger2
Copy link
Copy Markdown
Contributor

Closes #160

Bug found:

The sidebar navigation options fail to switch view content. Clicking options like "Transfer Vault" or "Beneficiaries" updates the active state styling on the item but does not render the respective view component, leaving the layout locked on a static view.

Root cause

  1. Sidebar click correctly updates activeTab, but the main dashboard layout does not use activeTab to control rendering
  2. All panels (TransactionsTable, TransferVault, BeneficiariesPanel, etc.) are rendered unconditionally at the same time
  3. No conditional rendering or mapping logic exists between activeTab state and displayed component
  4. Result: state changes only affect sidebar styling, not the visible view

Changes made:

  • Fixed routing logic for sidebar items
  • Corrected active link detection
  • Updated state handling for navigation clicks
  • Ensured sidebar reflects current route correctly

Fix applied:

  1. Remove simultaneous rendering of all dashboard panels in the main layout
  2. Link the main content rendering logic to the activeTab state
  3. Ensure only one component is displayed at a time based on the selected tab
  4. Replace static layout rendering with a dynamic view-switching mechanism
  5. Make sure sidebar tab values exactly match the keys used for rendering logic
  6. Keep activeTab as the single source of truth for navigation state

Testing done

  1. Reproduced the bug before applying fix.
  2. Confirmed fix resolves the issue .
  3. Verified no existing features are broken.
  4. Tested on: Chrome 147/1080 x 1920 desktop.

Screenshots:

image image

@Pragya79645
Copy link
Copy Markdown
Collaborator

your fix is still incomplete

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.

Sidebar navigation frozen

2 participants