aminghadersohi commented on code in PR #40563:
URL: https://github.com/apache/superset/pull/40563#discussion_r3417230487
##########
superset-frontend/src/SqlLab/components/SqlEditorTabHeader/index.tsx:
##########
@@ -220,6 +228,40 @@ const SqlEditorTabHeader: FC<Props> = ({ queryEditor }) =>
{
iconSize="m"
iconColor={getStatusColor(queryState, theme)}
/>{' '}
+ <Modal
Review Comment:
**CI failure — `sharded-jest-tests (7)`**
The "cancel button closes modal without dispatching" test is currently
failing in CI because `@superset-ui/core/components/Modal` keeps its children
mounted in the DOM when closed (Ant Design default). After clicking Cancel, the
`rename-tab-input` is still present in the DOM (`value="discarded"`), so
`expect(...).not.toBeInTheDocument()` fails.
Fix: add `destroyOnHidden` so the modal fully unmounts its children on close:
```suggestion
<Modal
destroyOnHidden
show={showRenameModal}
```
--
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]