Skip to content

fix(embedded): backport hideTab + filter-bar fix to 6.1 (#38846, #39417)#42008

Open
luizotavio32 wants to merge 2 commits into
apache:6.1from
luizotavio32:fix/backport-hideTab-with-filter-fix-6.1
Open

fix(embedded): backport hideTab + filter-bar fix to 6.1 (#38846, #39417)#42008
luizotavio32 wants to merge 2 commits into
apache:6.1from
luizotavio32:fix/backport-hideTab-with-filter-fix-6.1

Conversation

@luizotavio32

Copy link
Copy Markdown
Contributor

SUMMARY

Backport of two related embedded-dashboard fixes to the 6.1 branch.

hideTab (#38846) was previously cherry-picked to 6.1 on its own, but was reverted (3b7ddf88e9) because it introduced a regression (#39419): making hideTab: true actually skip rendering the Tabs component meant the useEffect inside Tabs never fired, so Redux activeTabs stayed []. useIsFilterInScope then treated every native filter as out-of-scope, producing a blank filter bar on embedded dashboards with tabs.

master/6.2 resolved this by shipping the hideTab fix together with its follow-up (#39417), which makes useActiveDashboardTabs fall back to a layout-derived default-tab path when activeTabs is empty. This PR brings both commits to 6.1 so the feature works without reintroducing the regression:

Note: the #39417 test file (state.test.ts) diverged from 6.1. During conflict resolution, two unrelated useChartCustomizationConfiguration ignores null/undefined items tests (which depend on behavior not present in 6.1) were dropped, as they are not part of #39417.

TESTING INSTRUCTIONS

  1. Set up an embedded dashboard with top-level tabs and native filters scoped per tab (e.g. one filter scoped to Tab A, another to Tab B).
  2. Load embedded fresh with hideTab: true in the SDK dashboardUiConfig — clear session storage.
  3. Expected: Tab bar is hidden; filter bar renders with the controls scoped to the default (first) tab; filters scoped only to non-default tabs stay hidden.
  4. Frontend unit tests: npx jest src/dashboard/components/nativeFilters/state.test.ts (25 passing).

ADDITIONAL INFORMATION

  • Changes UI
  • Has associated issue:
  • Required feature flags:
  • Includes DB Migration
  • Introduces new feature or API
  • Removes existing feature or API

Cherry-picks: #38846, #39417 (targets 6.1).

michael-s-molina and others added 2 commits July 13, 2026 16:19
…abs (apache#39417)

Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
(cherry picked from commit f27424d)
@dosubot dosubot Bot added change:frontend Requires changing the frontend dashboard:native-filters Related to the native filters of the Dashboard dashboard:tab Related to the usage of tabs in the Dashboard embedded labels Jul 13, 2026
@bito-code-review

bito-code-review Bot commented Jul 13, 2026

Copy link
Copy Markdown
Contributor

Bito Automatic Review Skipped - Branch Excluded

Bito didn't auto-review because the source or target branch is excluded from automatic reviews.
No action is needed if you didn't intend for the agent to review it. Otherwise, to manually trigger a review, type /review in a comment and save.
You can change the branch exclusion settings here, or contact your Bito workspace admin at evan@preset.io.

@luizotavio32

Copy link
Copy Markdown
Contributor Author

/review

@bito-code-review

bito-code-review Bot commented Jul 13, 2026

Copy link
Copy Markdown
Contributor

Code Review Agent Run #45ff38

Actionable Suggestions - 0
Additional Suggestions - 1
  • superset-frontend/src/dashboard/components/nativeFilters/state.ts - 1
    • Un-exported helper function limits testability · Line 187-187
      `useActiveDashboardTabs` (line 187) is defined as a plain function while `useDashboardLayout` (line 168) and `useDashboardHasTabs` (line 174) are both exported. This inconsistency blocks external consumers—including tests that need to directly unit-test the hook—from accessing `useActiveDashboardTabs`.
Filtered by Review Rules

Bito filtered these suggestions based on rules created automatically for your feedback. Manage rules.

  • superset-frontend/src/dashboard/components/nativeFilters/state.test.ts - 1
Review Details
  • Files reviewed - 3 · Commit Range: 2c6be54..87ffcbf
    • superset-frontend/src/dashboard/components/DashboardBuilder/DashboardBuilder.tsx
    • superset-frontend/src/dashboard/components/nativeFilters/state.test.ts
    • superset-frontend/src/dashboard/components/nativeFilters/state.ts
  • Files skipped - 0
  • Tools
    • Whispers (Secret Scanner) - ✔︎ Successful
    • Detect-secrets (Secret Scanner) - ✔︎ Successful
    • Eslint (Linter) - ✔︎ Successful

Bito Usage Guide

Commands

Type the following command in the pull request comment and save the comment.

  • /review - Manually triggers a full AI review.

  • /pause - Pauses automatic reviews on this pull request.

  • /resume - Resumes automatic reviews.

  • /resolve - Marks all Bito-posted review comments as resolved.

  • /abort - Cancels all in-progress reviews.

Refer to the documentation for additional commands.

Configuration

This repository uses Superset You can customize the agent settings here or contact your Bito workspace admin at evan@preset.io.

Documentation & Help

AI Code Review powered by Bito Logo

@netlify

netlify Bot commented Jul 13, 2026

Copy link
Copy Markdown

Deploy Preview for superset-docs-preview ready!

Name Link
🔨 Latest commit 87ffcbf
🔍 Latest deploy log https://app.netlify.com/projects/superset-docs-preview/deploys/6a553b05a9ece4000867d107
😎 Deploy Preview https://deploy-preview-42008--superset-docs-preview.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
🤖 Make changes Run an agent on this branch

To edit notification comments on pull requests, go to your Netlify project configuration.

@luizotavio32 luizotavio32 marked this pull request as ready for review July 13, 2026 19:47
@dosubot dosubot Bot added the embedded label Jul 13, 2026
@luizotavio32 luizotavio32 marked this pull request as draft July 13, 2026 19:49
@luizotavio32 luizotavio32 marked this pull request as ready for review July 13, 2026 19:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

change:frontend Requires changing the frontend dashboard:native-filters Related to the native filters of the Dashboard dashboard:tab Related to the usage of tabs in the Dashboard embedded size/XL

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants