Skip to content

fix(Node): wait for capabilities before tabs#3314

Merged
artemmufazalov merged 2 commits intomainfrom
3305-fix-node-tabs
Jan 14, 2026
Merged

fix(Node): wait for capabilities before tabs#3314
artemmufazalov merged 2 commits intomainfrom
3305-fix-node-tabs

Conversation

@artemmufazalov
Copy link
Member

@artemmufazalov artemmufazalov commented Jan 14, 2026

Closes #3305

Currently nodes tabs render before capabilities loaded, some tabs may appear, some other tabs may be hidden. Wait for capabilities and node data before showing content to ensure correct tabs list

CI Results

Test Status: ⚠️ FLAKY

📊 Full Report

Total Passed Failed Flaky Skipped
192 191 0 1 0

😟 No changes in tests. 😕

Bundle Size: ✅

Current: 62.67 MB | Main: 62.67 MB
Diff: +0.28 KB (0.00%)

✅ Bundle size unchanged.

ℹ️ CI Information
  • Test recordings for failed tests are available in the full report.
  • Bundle size is measured for the entire 'dist' directory.
  • 📊 indicates links to detailed reports.
  • 🔺 indicates increase, 🔽 decrease, and ✅ no change in bundle size.

Copilot AI review requested due to automatic review settings January 14, 2026 06:50
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR fixes an issue where node tabs were rendering before capabilities were fully loaded, causing tabs to incorrectly appear or disappear. The fix ensures that tab filtering only occurs after both node data and capabilities have loaded, preventing premature tab visibility changes.

Changes:

  • Renamed threadsQuantity to hasThreads for clearer boolean semantics
  • Added conditional logic to defer tab filtering until pageLoading is false
  • Added pageLoading check before rendering NodePageContent to prevent tabs from displaying during loading
  • Added pageLoading as a dependency to the useMemo hook that computes tabs

const actualNodeTabs = NODE_TABS.filter((el) => !skippedTabs.includes(el.id));
let actualNodeTabs = NODE_TABS;

// Do not reset tab when capabilities is not fully loaded
Copy link

Copilot AI Jan 14, 2026

Choose a reason for hiding this comment

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

The comment "Do not reset tab when capabilities is not fully loaded" is unclear or potentially misleading. The code filters tabs only when NOT loading (pageLoading is false), which means it shows ALL tabs during loading and filters them after loading completes. Consider revising the comment to be more explicit, such as "Show all tabs during loading, filter based on capabilities after loading completes" to better match the actual behavior.

Suggested change
// Do not reset tab when capabilities is not fully loaded
// Show all tabs while loading; filter tabs by capabilities after loading completes

Copilot uses AI. Check for mistakes.
@greptile-apps
Copy link
Contributor

greptile-apps bot commented Jan 14, 2026

Greptile's behavior is changing!

From now on, if a review finishes with no comments, we will not post an additional "statistics" comment to confirm that our review found nothing to comment on. However, you can confirm that we reviewed your changes in the status check section.

This feature can be toggled off in your Code Review Settings by deselecting "Create a status check for each PR".

@artemmufazalov artemmufazalov added this pull request to the merge queue Jan 14, 2026
Merged via the queue into main with commit 9c0cb57 Jan 14, 2026
9 checks passed
@artemmufazalov artemmufazalov deleted the 3305-fix-node-tabs branch January 14, 2026 07:34
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.

Node page tabs works badly

3 participants