RocketChat / RocketChat/Rocket.Chat

bug: Sidebar items depending on reactive settings do not update until page reload

Open
#39,817 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

triaged type: bug
Dominant language
TypeScript
Stars
46.1k
Forks
13.9k
Avg merge
3d 3h
Merged PRs (30d)
130

Description

Problem Statement

When an admin changes settings that control sidebar item visibility (for example Feature Preview navigation settings), the Account sidebar does not update reactively and requires a full page reload for the changes to appear.

This was observed when enabling/disabling Feature Preview -> Navigation -> Filters and secondary sidebar, but the issue appears to be related to the sidebar update mechanism itself rather than a specific feature.

Current Behavior

After changing a setting that affects sidebar item visibility, the sidebar does not update immediately. The change is only reflected after a full page reload.

Image

Expected Behavior

Sidebar items should appear immediately after the related setting is changed, without requiring a page reload.

Steps to Reproduce

  1. Go to Admin -> Settings -> Accounts
  2. Enable Feature Preview
  3. Inside Feature Preview, enable Navigation -> Filters and secondary sidebar
  4. Navigate back to Home without reloading
  5. Observe that the Filters / secondary sidebar does not appear
  6. Reload the page
  7. The Filters / secondary sidebar now appears

Possible Root Cause

The issue may be related to how sidebar items are managed and updated in 'apps/meteor/client/lib/createSidebarItems.ts' when settings change.

Settings themselves appear to update reactively, but the sidebar/navigation does not re-render until a full page reload, which suggests the sidebar update mechanism may not be reacting to setting changes.

It may be related to how sidebar items are registered or how subscribers are notified when settings change, but this would need confirmation from maintainers.

Suggested Fix (High Level)

Possible approaches could include:

  • Ensuring sidebar items are re-evaluated when relevant settings change
  • Triggering sidebar updates when reactive settings change
  • Reviewing the sidebar subscription/update mechanism

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the settings change described in the issue, then inspect apps/meteor/client/lib/createSidebarItems.ts and trace how sidebar items are registered and notified when settings change. Done means enabling or disabling the specified navigation settings updates the Account sidebar immediately without a page reload.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.