codeant-ai-for-open-source[bot] commented on code in PR #43454:
URL: https://github.com/apache/superset/pull/43454#discussion_r3843110280
##########
superset-frontend/src/explore/components/DataTablesPane/components/ResultsPaneOnDashboard.tsx:
##########
@@ -88,7 +88,12 @@ export const ResultsPaneOnDashboard = ({
return (
<Wrapper>
- <Tabs activeKey={activeTabKey} onChange={setActiveTabKey} items={items}
/>
+ <Tabs
+ fullHeight
+ activeKey={activeTabKey}
+ onChange={setActiveTabKey}
+ items={items}
Review Comment:
**Suggestion:** When the number of panes decreases, `activeTabKey` can still
reference a removed tab such as `results 2`. Since this component now passes
that stale key to `Tabs`, no item is active and the dashboard results area
renders blank. Reconcile the active key with `resultsPanes` and fall back to
`ResultTypes.Results`, as the sibling `DataTablesPane` does. [incorrect
condition logic]
<details>
<summary><b>Severity Level:</b> Major ⚠️</summary>
```mdx
- ❌ Chart Data modal can render blank after result panes shrink.
- ⚠️ Mixed and dynamic-query charts can lose remaining results.
```
</details>
[](https://docs.codeant.ai/cli/resolve-pr-comments-skill)
<details>
<summary><b>Prompt for AI Agent 🤖 </b></summary>
```mdx
This is a comment left during a code review.
**Path:**
superset-frontend/src/explore/components/DataTablesPane/components/ResultsPaneOnDashboard.tsx
**Line:** 91:95
**Comment:**
*Incorrect Condition Logic: When the number of panes decreases,
`activeTabKey` can still reference a removed tab such as `results 2`. Since
this component now passes that stale key to `Tabs`, no item is active and the
dashboard results area renders blank. Reconcile the active key with
`resultsPanes` and fall back to `ResultTypes.Results`, as the sibling
`DataTablesPane` does.
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%2F43454&comment_hash=a3fdcb9d9575740ccc79830f28ebac26a763e9c3d347c8683917ccc29a1c1320&reaction=like'>👍</a>
| <a
href='https://app.codeant.ai/feedback?pr_url=https%3A%2F%2Fgithub.com%2Fapache%2Fsuperset%2Fpull%2F43454&comment_hash=a3fdcb9d9575740ccc79830f28ebac26a763e9c3d347c8683917ccc29a1c1320&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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]