You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by "rusackas (via GitHub)" <gi...@apache.org> on 2026/02/22 06:46:13 UTC
[PR] fix(FilterBar): always show 'More filters' button when items exist [superset]
rusackas opened a new pull request, #38162:
URL: https://github.com/apache/superset/pull/38162
## Summary
Fixes #28060 - "Default filters values cause filter fields to disappear in dashboards"
This PR fixes an issue where the "More filters" button would disappear when filter values were set to their defaults and nothing was overflowing the filter bar container.
### Changes
- Added `shouldShowButton` flag in `DropdownContainer` that ensures the button is always visible when items exist
- The button now remains stable regardless of overflow state, preventing layout shifts
- The badge correctly shows 0 when nothing is overflowing
- Updated tests to reflect the new expected behavior
### Root Cause
The button rendering was conditioned on `popoverContent` being truthy, which required either:
1. `dropdownContent` prop to be defined, OR
2. `overflowingCount > 0`
When neither condition was met (common when all filters fit in the container with default values), the button would completely disappear.
### Before/After
| Before | After |
|--------|-------|
| Button disappears when no overflow | Button always visible with badge showing "0" |
| Layout shifts when resizing window | Consistent, stable UI |
## Test plan
1. Create a dashboard with multiple filters
2. Set all filters to their default values
3. Make the filter bar wide enough that nothing overflows
4. ✅ Verify the "More filters" button remains visible with a "0" badge
5. ✅ Resize the window to trigger overflow - button should update count accordingly
🤖 Generated with [Claude Code](https://claude.ai/code)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [PR] fix(FilterBar): always show 'More filters' button when items exist [superset]
Posted by "rusackas (via GitHub)" <gi...@apache.org>.
rusackas commented on PR #38162:
URL: https://github.com/apache/superset/pull/38162#issuecomment-4713961474
Superseded by #38193. Closing this AND the issue.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [PR] fix(FilterBar): always show 'More filters' button when items exist [superset]
Posted by "netlify[bot] (via GitHub)" <gi...@apache.org>.
netlify[bot] commented on PR #38162:
URL: https://github.com/apache/superset/pull/38162#issuecomment-4299322003
### <span aria-hidden="true">✅</span> Deploy Preview for *superset-docs-preview* ready!
| Name | Link |
|:-:|------------------------|
|<span aria-hidden="true">🔨</span> Latest commit | f3651a7065252f6f2c7ebe992fd45022fb5ea28e |
|<span aria-hidden="true">🔍</span> Latest deploy log | https://app.netlify.com/projects/superset-docs-preview/deploys/69e91f00e9d940000811d4ee |
|<span aria-hidden="true">😎</span> Deploy Preview | [https://deploy-preview-38162--superset-docs-preview.netlify.app](https://deploy-preview-38162--superset-docs-preview.netlify.app) |
|<span aria-hidden="true">📱</span> Preview on mobile | <details><summary> Toggle QR Code... </summary><br /><br /><br /><br />_Use your smartphone camera to open QR code link._</details> |
---
<!-- [superset-docs-preview Preview](https://deploy-preview-38162--superset-docs-preview.netlify.app) -->
_To edit notification comments on pull requests, go to your [Netlify project configuration](https://app.netlify.com/projects/superset-docs-preview/configuration/notifications#deploy-notifications)._
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [PR] fix(FilterBar): always show 'More filters' button when items exist [superset]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #38162:
URL: https://github.com/apache/superset/pull/38162#issuecomment-3999375939
🎪 [Showtime](https://github.com/mistercrunch/superset-showtime) is building environment on [GHA](https://github.com/apache/superset/actions/runs/22683428449) for [45c05d3](https://github.com/apache/superset/commit/45c05d3)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [PR] fix(FilterBar): always show 'More filters' button when items exist [superset]
Posted by "rusackas (via GitHub)" <gi...@apache.org>.
rusackas commented on PR #38162:
URL: https://github.com/apache/superset/pull/38162#issuecomment-4713422685
@aminghadersohi thanks for the careful read. Pinned the disabled state with a `toBeDisabled()` assertion and expanded the comment to spell out the disabled/0-badge trade-off — both in ed14e8b9d7. Left the `<Global>` block as-is since the styles are inert when nothing can open; happy to gate it on `popoverContent` too if you'd rather not pay the unused-CSS cost.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [PR] fix(FilterBar): always show 'More filters' button when items exist [superset]
Posted by "bito-code-review[bot] (via GitHub)" <gi...@apache.org>.
bito-code-review[bot] commented on PR #38162:
URL: https://github.com/apache/superset/pull/38162#issuecomment-4714357074
AI Code Review is in progress (usually takes 3 to 15 minutes unless it's a very large PR).
<details>
<summary>
Bito Usage Guide
</summary>
**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 <a href="https://docs.bito.ai/bito-dev-agents/ai-code-review-agent/available-commands" target="_blank" rel="noopener noreferrer">documentation</a> for additional commands.
**Configuration**
This repository uses `Superset` You can customize the agent settings <a href="https://alpha.bito.ai/home/ai-agents/code-review-agent" target="_blank" rel="noopener noreferrer">here</a> or contact your Bito workspace admin at evan@preset.io.
**Documentation & Help**
- <a href="https://docs.bito.ai/bito-dev-agents/ai-code-review-agent/getting-started/install-run-using-bito-cloud/create-or-customize-an-agent-instance" target="_blank" rel="noopener noreferrer">Customize agent settings</a>
- <a href="https://docs.bito.ai/bito-dev-agents/ai-code-review-agent/implementing-custom-code-review-rules" target="_blank" rel="noopener noreferrer">Review rules</a>
- <a href="https://docs.bito.ai/bito-dev-agents/ai-code-review-agent" target="_blank" rel="noopener noreferrer">General documentation</a>
- <a href="https://docs.bito.ai/bito-dev-agents/ai-code-review-agent/faqs" target="_blank" rel="noopener noreferrer">FAQ</a>
</details>
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [PR] fix(FilterBar): always show 'More filters' button when items exist [superset]
Posted by "bito-code-review[bot] (via GitHub)" <gi...@apache.org>.
bito-code-review[bot] commented on PR #38162:
URL: https://github.com/apache/superset/pull/38162#issuecomment-4299684748
AI Code Review is in progress (usually takes 3 to 15 minutes unless it's a very large PR).
<details>
<summary>
Bito Usage Guide
</summary>
**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 <a href="https://docs.bito.ai/bito-dev-agents/ai-code-review-agent/available-commands" target="_blank" rel="noopener noreferrer">documentation</a> for additional commands.
**Configuration**
This repository uses `Superset` You can customize the agent settings <a href="https://alpha.bito.ai/home/ai-agents/code-review-agent" target="_blank" rel="noopener noreferrer">here</a> or contact your Bito workspace admin at evan@preset.io.
**Documentation & Help**
- <a href="https://docs.bito.ai/bito-dev-agents/ai-code-review-agent/getting-started/install-run-using-bito-cloud/create-or-customize-an-agent-instance" target="_blank" rel="noopener noreferrer">Customize agent settings</a>
- <a href="https://docs.bito.ai/bito-dev-agents/ai-code-review-agent/implementing-custom-code-review-rules" target="_blank" rel="noopener noreferrer">Review rules</a>
- <a href="https://docs.bito.ai/bito-dev-agents/ai-code-review-agent" target="_blank" rel="noopener noreferrer">General documentation</a>
- <a href="https://docs.bito.ai/bito-dev-agents/ai-code-review-agent/faqs" target="_blank" rel="noopener noreferrer">FAQ</a>
</details>
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [PR] fix(FilterBar): always show 'More filters' button when items exist [superset]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #38162:
URL: https://github.com/apache/superset/pull/38162#issuecomment-3999488432
🎪 [Showtime](https://github.com/mistercrunch/superset-showtime) deployed environment on [GHA](https://github.com/apache/superset/actions/runs/22683428449) for [45c05d3](https://github.com/apache/superset/commit/45c05d3)
• **Environment:** http://54.191.59.202:8080 (admin/admin)
• **Lifetime:** 48h auto-cleanup
• **Updates:** New commits create fresh environments automatically
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [PR] fix(FilterBar): always show 'More filters' button when items exist [superset]
Posted by "dosubot[bot] (via GitHub)" <gi...@apache.org>.
dosubot[bot] commented on PR #38162:
URL: https://github.com/apache/superset/pull/38162#issuecomment-3940301573
<!-- Answer -->
**Related Documentation**
Checked 0 published document(s) in 2 knowledge base(s). No updates required.
<!-- Dosu Comment Footer -->
<sup>How did I do? Any feedback?</sup> [](https://go.dosu.dev/discord-bot)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [PR] fix(FilterBar): always show 'More filters' button when items exist [superset]
Posted by "jaymasiwal (via GitHub)" <gi...@apache.org>.
jaymasiwal commented on PR #38162:
URL: https://github.com/apache/superset/pull/38162#issuecomment-4025219058
Thanks for the clarification — that makes sense.
From the UI behavior during testing it looked like the button was rendered even when there was no actual overflow content, which is why I initially thought guarding the Popover might help.
If the real issue is with how the overflow calculation works, I'm happy to take a look at that logic in `DropdownContainer` and see where the overflow detection might be off.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [PR] fix(FilterBar): always show 'More filters' button when items exist [superset]
Posted by "codeant-ai-for-open-source[bot] (via GitHub)" <gi...@apache.org>.
codeant-ai-for-open-source[bot] commented on code in PR #38162:
URL: https://github.com/apache/superset/pull/38162#discussion_r3126398720
##########
superset-frontend/packages/superset-ui-core/src/components/DropdownContainer/DropdownContainer.tsx:
##########
@@ -293,6 +297,45 @@ export const DropdownContainer = forwardRef(
};
}, [popoverVisible]);
+ const triggerButton = (
+ <Tooltip title={dropdownTriggerTooltip}>
+ <Button
+ buttonStyle="secondary"
+ data-test="dropdown-container-btn"
+ icon={dropdownTriggerIcon}
+ disabled={!popoverContent}
+ css={css`
+ padding-left: ${theme.paddingXS}px;
+ padding-right: ${theme.paddingXXS}px;
+ gap: ${theme.sizeXXS}px;
+ `}
+ >
Review Comment:
**Suggestion:** The tooltip is wrapped directly around a disabled `Button`, but disabled Ant Design buttons do not emit hover/focus events, so the tooltip will not appear in the exact state this PR introduces (button visible with no popover content). This breaks the "No applied filters" hint for users. Use the `Button` component's built-in `tooltip` prop (which already handles disabled buttons with a wrapper) or wrap the disabled trigger in a non-disabled element (like `span`) before applying `Tooltip`. [logic error]
<details>
<summary><b>Severity Level:</b> Major ⚠️</summary>
```mdx
- ⚠️ Horizontal native filter bar tooltip never shows for zero overflow.
- ⚠️ Users lack hover feedback on disabled "More filters" button.
```
</details>
<details>
<summary><b>Steps of Reproduction ✅ </b></summary>
```mdx
1. Open any dashboard that uses the horizontal native filter bar, which renders
`HorizontalFilterBar` from
`superset-frontend/src/dashboard/components/nativeFilters/FilterBar/Horizontal.tsx:45-80`.
Ensure there is at least one native filter or cross-filter so `hasFilters` is true (lines
74-77), which causes `<FilterControls />` to render (lines 13-23).
2. In that dashboard, configure filters so that: (a) the filter bar is wide enough that no
filters overflow into the "More filters" dropdown, and (b) no overflow-specific filters
are active. In code, this corresponds to `overflowedFiltersInScope.length`,
`overflowedCrossFilters.length`, `filtersOutOfScope.length`, and
`customizationsOutOfScope.length` all being falsy so `dropdownContent` is `undefined` in
`FilterControls` at
`superset-frontend/src/dashboard/components/nativeFilters/FilterBar/FilterControls/FilterControls.tsx:61-67`,
and `activeOverflowedFiltersInScope.length === 0` so `dropdownTriggerTooltip` is set to
`t('No applied filters')` (lines 51-59).
3. With those props, `DropdownContainer` (this PR's file) computes `overflowingCount` as
`0` when `overflowingIndex === -1` (lines 234-235), then `shouldShowButton` as `true`
because `items.length > 0` (line 239), and `popoverContent` as `null` because both
`dropdownContent` and `overflowingCount` are falsy in the `useMemo` at lines 241-258. As a
result, the trigger button is rendered directly (not inside a `<Popover>`) via the
`{popoverContent ? <Popover> : triggerButton}` branch at lines 385-404.
4. In that same `DropdownContainer` component, the trigger button is defined as `const
triggerButton = (` at line 300 wrapping a `Tooltip` around a `Button` (lines 300-317). The
`Button` is disabled when there is no popover content (`disabled={!popoverContent}` at
line 306), so in this "no overflow, no extra content" state it is disabled. The `Button`
implementation in
`superset-frontend/packages/superset-ui-core/src/components/Button/index.tsx:49-170` shows
it renders an Ant Design `<Button>` (`AntdButton` at lines 101-146), and only when the
`tooltip` prop is used does it wrap the button in a `<span>` to allow tooltips on disabled
buttons (lines 149-168). Here, however, `DropdownContainer` uses the raw `Tooltip` wrapper
around a disabled `Button` instead of the `Button`'s `tooltip` prop, so the Ant Design
tooltip never fires for the disabled element. In the running UI, hovering the "More
filters" button in the horizontal filter bar while no filters are overflowing and
`activeOverflowedFiltersInScope.length === 0` does not show the expected "No applied
filters" tooltip, even though `dropdownTriggerTooltip` is set.
```
</details>
[Fix in Cursor](https://app.codeant.ai/fix-in-ide?tool=cursor&prompt=This%20is%20a%20comment%20left%20during%20a%20code%20review.%0A%0A%2A%2APath%3A%2A%2A%20superset-frontend%2Fpackages%2Fsuperset-ui-core%2Fsrc%2Fcomponents%2FDropdownContainer%2FDropdownContainer.tsx%0A%2A%2ALine%3A%2A%2A%20300%3A312%0A%2A%2AComment%3A%2A%2A%0A%09%2ALogic%20Error%3A%20The%20tooltip%20is%20wrapped%20directly%20around%20a%20disabled%20%60Button%60%2C%20but%20disabled%20Ant%20Design%20buttons%20do%20not%20emit%20hover%2Ffocus%20events%2C%20so%20the%20tooltip%20will%20not%20appear%20in%20the%20exact%20state%20this%20PR%20introduces%20%28button%20visible%20with%20no%20popover%20content%29.%20This%20breaks%20the%20%22No%20applied%20filters%22%20hint%20for%20users.%20Use%20the%20%60Button%60%20component%27s%20built-in%20%60tooltip%60%20prop%20%28which%20already%20handles%20disabled%20buttons%20with%20a%20wrapper%29%20or%20wrap%20the%20disabled%20trigger%20in%20a%20non-disabled%20element%20%28like%20%60sp
an%60%29%20before%20applying%20%60Tooltip%60.%0A%0AValidate%20the%20correctness%20of%20the%20flagged%20issue.%20If%20correct%2C%20How%20can%20I%20resolve%20this%3F%20If%20you%20propose%20a%20fix%2C%20implement%20it%20and%20please%20make%20it%20concise.%0AOnce%20fix%20is%20implemented%2C%20also%20check%20other%20comments%20on%20the%20same%20PR%2C%20and%20ask%20user%20if%20the%20user%20wants%20to%20fix%20the%20rest%20of%20the%20comments%20as%20well.%20if%20said%20yes%2C%20then%20fetch%20all%20the%20comments%20validate%20the%20correctness%20and%20implement%20a%20minimal%20fix%0A) | [Fix in VSCode Claude](https://app.codeant.ai/fix-in-ide?tool=vscode-claude&prompt=This%20is%20a%20comment%20left%20during%20a%20code%20review.%0A%0A%2A%2APath%3A%2A%2A%20superset-frontend%2Fpackages%2Fsuperset-ui-core%2Fsrc%2Fcomponents%2FDropdownContainer%2FDropdownContainer.tsx%0A%2A%2ALine%3A%2A%2A%20300%3A312%0A%2A%2AComment%3A%2A%2A%0A%09%2ALogic%20Error%3A%20The%20tooltip%20is%20wrapped%20directly%20a
round%20a%20disabled%20%60Button%60%2C%20but%20disabled%20Ant%20Design%20buttons%20do%20not%20emit%20hover%2Ffocus%20events%2C%20so%20the%20tooltip%20will%20not%20appear%20in%20the%20exact%20state%20this%20PR%20introduces%20%28button%20visible%20with%20no%20popover%20content%29.%20This%20breaks%20the%20%22No%20applied%20filters%22%20hint%20for%20users.%20Use%20the%20%60Button%60%20component%27s%20built-in%20%60tooltip%60%20prop%20%28which%20already%20handles%20disabled%20buttons%20with%20a%20wrapper%29%20or%20wrap%20the%20disabled%20trigger%20in%20a%20non-disabled%20element%20%28like%20%60span%60%29%20before%20applying%20%60Tooltip%60.%0A%0AValidate%20the%20correctness%20of%20the%20flagged%20issue.%20If%20correct%2C%20How%20can%20I%20resolve%20this%3F%20If%20you%20propose%20a%20fix%2C%20implement%20it%20and%20please%20make%20it%20concise.%0AOnce%20fix%20is%20implemented%2C%20also%20check%20other%20comments%20on%20the%20same%20PR%2C%20and%20ask%20user%20if%20the%20user%20wants%20to%2
0fix%20the%20rest%20of%20the%20comments%20as%20well.%20if%20said%20yes%2C%20then%20fetch%20all%20the%20comments%20validate%20the%20correctness%20and%20implement%20a%20minimal%20fix%0A)
*(Use Cmd/Ctrl + Click for best experience)*
<details>
<summary><b>Prompt for AI Agent 🤖 </b></summary>
```mdx
This is a comment left during a code review.
**Path:** superset-frontend/packages/superset-ui-core/src/components/DropdownContainer/DropdownContainer.tsx
**Line:** 300:312
**Comment:**
*Logic Error: The tooltip is wrapped directly around a disabled `Button`, but disabled Ant Design buttons do not emit hover/focus events, so the tooltip will not appear in the exact state this PR introduces (button visible with no popover content). This breaks the "No applied filters" hint for users. Use the `Button` component's built-in `tooltip` prop (which already handles disabled buttons with a wrapper) or wrap the disabled trigger in a non-disabled element (like `span`) before applying `Tooltip`.
Validate the correctness of the flagged issue. If correct, How can I resolve this? If you propose a fix, implement it and please make it concise.
Once fix is implemented, also check other comments on the same PR, and ask user if the user wants to fix the rest of the comments as well. if said yes, then fetch all the comments validate the correctness and implement a minimal fix
```
</details>
<a href='https://app.codeant.ai/feedback?pr_url=https%3A%2F%2Fgithub.com%2Fapache%2Fsuperset%2Fpull%2F38162&comment_hash=95679283d2336b58f56b4effac2ca39bcec3cdb02d0e275771836ebe21f87242&reaction=like'>👍</a> | <a href='https://app.codeant.ai/feedback?pr_url=https%3A%2F%2Fgithub.com%2Fapache%2Fsuperset%2Fpull%2F38162&comment_hash=95679283d2336b58f56b4effac2ca39bcec3cdb02d0e275771836ebe21f87242&reaction=dislike'>👎</a>
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [PR] fix(FilterBar): always show 'More filters' button when items exist [superset]
Posted by "bito-code-review[bot] (via GitHub)" <gi...@apache.org>.
bito-code-review[bot] commented on PR #38162:
URL: https://github.com/apache/superset/pull/38162#issuecomment-4637656296
AI Code Review is in progress (usually takes 3 to 15 minutes unless it's a very large PR).
<details>
<summary>
Bito Usage Guide
</summary>
**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 <a href="https://docs.bito.ai/bito-dev-agents/ai-code-review-agent/available-commands" target="_blank" rel="noopener noreferrer">documentation</a> for additional commands.
**Configuration**
This repository uses `Superset` You can customize the agent settings <a href="https://alpha.bito.ai/home/ai-agents/code-review-agent" target="_blank" rel="noopener noreferrer">here</a> or contact your Bito workspace admin at evan@preset.io.
**Documentation & Help**
- <a href="https://docs.bito.ai/bito-dev-agents/ai-code-review-agent/getting-started/install-run-using-bito-cloud/create-or-customize-an-agent-instance" target="_blank" rel="noopener noreferrer">Customize agent settings</a>
- <a href="https://docs.bito.ai/bito-dev-agents/ai-code-review-agent/implementing-custom-code-review-rules" target="_blank" rel="noopener noreferrer">Review rules</a>
- <a href="https://docs.bito.ai/bito-dev-agents/ai-code-review-agent" target="_blank" rel="noopener noreferrer">General documentation</a>
- <a href="https://docs.bito.ai/bito-dev-agents/ai-code-review-agent/faqs" target="_blank" rel="noopener noreferrer">FAQ</a>
</details>
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [PR] fix(FilterBar): always show 'More filters' button when items exist [superset]
Posted by "rusackas (via GitHub)" <gi...@apache.org>.
rusackas closed pull request #38162: fix(FilterBar): always show 'More filters' button when items exist
URL: https://github.com/apache/superset/pull/38162
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [PR] fix(FilterBar): always show 'More filters' button when items exist [superset]
Posted by "jaymasiwal (via GitHub)" <gi...@apache.org>.
jaymasiwal commented on PR #38162:
URL: https://github.com/apache/superset/pull/38162#issuecomment-4025330574
While looking at `DropdownContainer.tsx`, I noticed the overflow detection relies on:
```ts
const index = childrenArray.findIndex(
child =>
child.getBoundingClientRect().right >
container.getBoundingClientRect().right + 1,
);
```
So if no element crosses the container boundary, `index` becomes `-1`, which results in `overflowingCount = 0`.
With the current change that always renders the button when items exist, that leads to the visible **"More filters (0)"** state with no popover content.
Do you think the fix should adjust how `overflowingIndex` is determined (for example ensuring the button itself is accounted for when calculating available space), rather than guarding the Popover?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [PR] fix(FilterBar): always show 'More filters' button when items exist [superset]
Posted by "jaymasiwal (via GitHub)" <gi...@apache.org>.
jaymasiwal commented on PR #38162:
URL: https://github.com/apache/superset/pull/38162#issuecomment-4006852448
If helpful, I can open a small follow-up PR to guard the Popover rendering when `popoverContent` is null so the button doesn't trigger an empty overlay.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [PR] fix(FilterBar): always show 'More filters' button when items exist [superset]
Posted by "bito-code-review[bot] (via GitHub)" <gi...@apache.org>.
bito-code-review[bot] commented on PR #38162:
URL: https://github.com/apache/superset/pull/38162#issuecomment-3940301604
AI Code Review is in progress (usually takes 3 to 15 minutes unless it's a very large PR).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [PR] fix(FilterBar): always show 'More filters' button when items exist [superset]
Posted by "codeant-ai-for-open-source[bot] (via GitHub)" <gi...@apache.org>.
codeant-ai-for-open-source[bot] commented on PR #38162:
URL: https://github.com/apache/superset/pull/38162#issuecomment-3940302914
## **Sequence Diagram**
The PR makes the DropdownContainer always render the "More" button when any items exist, computing an overflowingCount (which can be 0) to show on the badge; clicking the button opens either provided dropdownContent or the list of overflowed items.
```mermaid
sequenceDiagram
participant Renderer as App/Renderer
participant Dropdown as DropdownContainer
participant Badge as OverflowBadge
participant Popover as PopoverContent
Renderer->>Dropdown: Render with items[]
Dropdown->>Dropdown: compute overflowingCount (>=0) and shouldShowButton (items.length > 0 || dropdownContent)
Dropdown-->>Badge: show "More" button with count = overflowingCount
User->>Dropdown: Click "More" button
Dropdown->>Popover: open popover with (dropdownContent || overflowed items)
```
---
*Generated by [CodeAnt AI](https://codeant.ai)*
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [PR] fix(FilterBar): always show 'More filters' button when items exist [superset]
Posted by "rusackas (via GitHub)" <gi...@apache.org>.
rusackas commented on code in PR #38162:
URL: https://github.com/apache/superset/pull/38162#discussion_r3126379250
##########
superset-frontend/packages/superset-ui-core/src/components/DropdownContainer/DropdownContainer.tsx:
##########
@@ -314,7 +318,7 @@ export const DropdownContainer = forwardRef(
>
{notOverflowedItems.map(item => item.element)}
</div>
- {popoverContent && (
+ {shouldShowButton && (
<>
<Global
styles={css`
Review Comment:
Good catch — fixed in f3651a7. The trigger button is now rendered bare (no `Popover` wrapper) when `popoverContent` is null, and it's also marked `disabled` in that state so it can't be clicked to open an empty overlay. The layout-stability goal of the PR still holds because the button itself is always in the DOM whenever items exist.
##########
superset-frontend/packages/superset-ui-core/src/components/DropdownContainer/DropdownContainer.tsx:
##########
@@ -234,6 +234,10 @@ export const DropdownContainer = forwardRef(
const overflowingCount =
overflowingIndex !== -1 ? items.length - overflowingIndex : 0;
+ // Always show button when items exist to prevent layout shifts
+ // and ensure consistent UI even when nothing is currently overflowing
Review Comment:
Applied the suggestion in 795801e — swapped "currently" for the timeless phrasing.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [PR] fix(FilterBar): always show 'More filters' button when items exist [superset]
Posted by "bito-code-review[bot] (via GitHub)" <gi...@apache.org>.
bito-code-review[bot] commented on PR #38162:
URL: https://github.com/apache/superset/pull/38162#issuecomment-4300730860
AI Code Review is in progress (usually takes 3 to 15 minutes unless it's a very large PR).
<details>
<summary>
Bito Usage Guide
</summary>
**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 <a href="https://docs.bito.ai/bito-dev-agents/ai-code-review-agent/available-commands" target="_blank" rel="noopener noreferrer">documentation</a> for additional commands.
**Configuration**
This repository uses `Superset` You can customize the agent settings <a href="https://alpha.bito.ai/home/ai-agents/code-review-agent" target="_blank" rel="noopener noreferrer">here</a> or contact your Bito workspace admin at evan@preset.io.
**Documentation & Help**
- <a href="https://docs.bito.ai/bito-dev-agents/ai-code-review-agent/getting-started/install-run-using-bito-cloud/create-or-customize-an-agent-instance" target="_blank" rel="noopener noreferrer">Customize agent settings</a>
- <a href="https://docs.bito.ai/bito-dev-agents/ai-code-review-agent/implementing-custom-code-review-rules" target="_blank" rel="noopener noreferrer">Review rules</a>
- <a href="https://docs.bito.ai/bito-dev-agents/ai-code-review-agent" target="_blank" rel="noopener noreferrer">General documentation</a>
- <a href="https://docs.bito.ai/bito-dev-agents/ai-code-review-agent/faqs" target="_blank" rel="noopener noreferrer">FAQ</a>
</details>
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [PR] fix(FilterBar): always show 'More filters' button when items exist [superset]
Posted by "codecov[bot] (via GitHub)" <gi...@apache.org>.
codecov[bot] commented on PR #38162:
URL: https://github.com/apache/superset/pull/38162#issuecomment-4300562130
## [Codecov](https://app.codecov.io/gh/apache/superset/pull/38162?dropdown=coverage&src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) Report
:x: Patch coverage is `90.90909%` with `1 line` in your changes missing coverage. Please review.
:white_check_mark: Project coverage is 64.58%. Comparing base ([`0d68133`](https://app.codecov.io/gh/apache/superset/commit/0d681338aa846cbdbe1d173d0f7377f92a4c9bcc?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)) to head ([`bf6e779`](https://app.codecov.io/gh/apache/superset/commit/bf6e779200aee079e700db3d97e1634ef8ca7a07?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)).
:warning: Report is 2 commits behind head on master.
| [Files with missing lines](https://app.codecov.io/gh/apache/superset/pull/38162?dropdown=coverage&src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | Patch % | Lines |
|---|---|---|
| [...components/DropdownContainer/DropdownContainer.tsx](https://app.codecov.io/gh/apache/superset/pull/38162?src=pr&el=tree&filepath=superset-frontend%2Fpackages%2Fsuperset-ui-core%2Fsrc%2Fcomponents%2FDropdownContainer%2FDropdownContainer.tsx&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#diff-c3VwZXJzZXQtZnJvbnRlbmQvcGFja2FnZXMvc3VwZXJzZXQtdWktY29yZS9zcmMvY29tcG9uZW50cy9Ecm9wZG93bkNvbnRhaW5lci9Ecm9wZG93bkNvbnRhaW5lci50c3g=) | 90.90% | [1 Missing :warning: ](https://app.codecov.io/gh/apache/superset/pull/38162?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) |
<details><summary>Additional details and impacted files</summary>
```diff
@@ Coverage Diff @@
## master #38162 +/- ##
=======================================
Coverage 64.58% 64.58%
=======================================
Files 2564 2564
Lines 133560 133564 +4
Branches 31032 31035 +3
=======================================
+ Hits 86256 86261 +5
+ Misses 45812 45811 -1
Partials 1492 1492
```
| [Flag](https://app.codecov.io/gh/apache/superset/pull/38162/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | Coverage Δ | |
|---|---|---|
| [javascript](https://app.codecov.io/gh/apache/superset/pull/38162/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `66.54% <90.90%> (+<0.01%)` | :arrow_up: |
Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#carryforward-flags-in-the-pull-request-comment) to find out more.
</details>
[:umbrella: View full report in Codecov by Sentry](https://app.codecov.io/gh/apache/superset/pull/38162?dropdown=coverage&src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache).
:loudspeaker: Have feedback on the report? [Share it here](https://about.codecov.io/codecov-pr-comment-feedback/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache).
<details><summary> :rocket: New features to boost your workflow: </summary>
- :snowflake: [Test Analytics](https://docs.codecov.com/docs/test-analytics): Detect flaky tests, report on failures, and find test suite problems.
- :package: [JS Bundle Analysis](https://docs.codecov.com/docs/javascript-bundle-analysis): Save yourself from yourself by tracking and limiting bundle sizes in JS merges.
</details>
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [PR] fix(FilterBar): always show 'More filters' button when items exist [superset]
Posted by "Copilot (via GitHub)" <gi...@apache.org>.
Copilot commented on code in PR #38162:
URL: https://github.com/apache/superset/pull/38162#discussion_r2885406382
##########
superset-frontend/packages/superset-ui-core/src/components/DropdownContainer/DropdownContainer.tsx:
##########
@@ -314,7 +318,7 @@ export const DropdownContainer = forwardRef(
>
{notOverflowedItems.map(item => item.element)}
</div>
- {popoverContent && (
+ {shouldShowButton && (
<>
<Global
styles={css`
Review Comment:
`shouldShowButton` can be true while `popoverContent` is `null` (items exist, nothing overflows, and `dropdownContent` is undefined). Since the Popover is still rendered, clicking the button can open an empty popover overlay. Consider rendering the button without the Popover wrapper when `popoverContent` is null, or guarding Popover open/trigger so it can’t open unless there is content to show.
##########
superset-frontend/packages/superset-ui-core/src/components/DropdownContainer/DropdownContainer.tsx:
##########
@@ -234,6 +234,10 @@ export const DropdownContainer = forwardRef(
const overflowingCount =
overflowingIndex !== -1 ? items.length - overflowingIndex : 0;
+ // Always show button when items exist to prevent layout shifts
+ // and ensure consistent UI even when nothing is currently overflowing
Review Comment:
The new inline comment uses time-specific wording (“currently overflowing”). The repo’s guidance prefers timeless comments to avoid becoming outdated; consider rephrasing to remove “currently” while keeping the intent.
```suggestion
// and ensure consistent UI even when no items are overflowing
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [PR] fix(FilterBar): always show 'More filters' button when items exist [superset]
Posted by "rusackas (via GitHub)" <gi...@apache.org>.
rusackas commented on PR #38162:
URL: https://github.com/apache/superset/pull/38162#issuecomment-4307621925
@michael-s-molina @mistercrunch — gentle ping on this one: CI is green and the only open thread is an outdated bot suggestion. Let me know if either of you has bandwidth to take a look this week.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [PR] fix(FilterBar): always show 'More filters' button when items exist [superset]
Posted by "jaymasiwal (via GitHub)" <gi...@apache.org>.
jaymasiwal commented on PR #38162:
URL: https://github.com/apache/superset/pull/38162#issuecomment-4006844909
I tested the PR using the preview environment.
When filters fit in the bar (no overflow), the **“More filters (0)” button remains visible as expected**, which fixes the layout shift issue described in the PR.
However, when clicking the button in this state, **nothing happens** because there is no overflow content to render.
This seems to match the Copilot review note that `shouldShowButton` can be true while `popoverContent` is null. In this case the button is still rendered but the popover has no content.
From a UX perspective it might be worth either:
• disabling the button when `popoverContent` is null
• or rendering the button without the popover wrapper when there is no content
Just sharing the behavior observed during testing in the preview environment.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [PR] fix(FilterBar): always show 'More filters' button when items exist [superset]
Posted by "rusackas (via GitHub)" <gi...@apache.org>.
rusackas commented on PR #38162:
URL: https://github.com/apache/superset/pull/38162#issuecomment-4710987071
Adding another reviewer, since the previous requests have gone unheeded. Hoping to merge this one :D
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [PR] fix(FilterBar): always show 'More filters' button when items exist [superset]
Posted by "rusackas (via GitHub)" <gi...@apache.org>.
rusackas commented on code in PR #38162:
URL: https://github.com/apache/superset/pull/38162#discussion_r3211835893
##########
superset-frontend/packages/superset-ui-core/src/components/DropdownContainer/DropdownContainer.tsx:
##########
@@ -293,6 +297,45 @@ export const DropdownContainer = forwardRef(
};
}, [popoverVisible]);
+ const triggerButton = (
+ <Tooltip title={dropdownTriggerTooltip}>
+ <Button
+ buttonStyle="secondary"
+ data-test="dropdown-container-btn"
+ icon={dropdownTriggerIcon}
+ disabled={!popoverContent}
+ css={css`
+ padding-left: ${theme.paddingXS}px;
+ padding-right: ${theme.paddingXXS}px;
+ gap: ${theme.sizeXXS}px;
+ `}
+ >
Review Comment:
Already addressed in bf6e779 — switched to the `Button` component's built-in `tooltip` prop, which wraps disabled buttons in a `<span>` so hover/focus reaches the tooltip.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org