You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@superset.apache.org by ma...@apache.org on 2026/04/09 21:32:26 UTC

(superset) 02/05: fix(SqlLab): fix SQL modal padding and vertical overflow

This is an automated email from the ASF dual-hosted git repository.

maximebeauchemin pushed a commit to branch sql-popover-fix
in repository https://gitbox.apache.org/repos/asf/superset.git

commit cf333ccd4d8b8146903474749d940904cc746029
Author: Maxime Beauchemin <ma...@gmail.com>
AuthorDate: Thu Apr 9 19:50:52 2026 +0000

    fix(SqlLab): fix SQL modal padding and vertical overflow
    
    The modal body content had a negative margin (-sizeUnit*6 on all sides)
    that was pulling content outside the scrollable area (breaking overflow)
    and stripping padding from the Source/Executed SQL titles. Removing it
    lets the modal body's built-in padding apply naturally.
    
    Co-Authored-By: Claude Opus 4.6 <no...@anthropic.com>
---
 superset-frontend/src/SqlLab/components/HighlightedSql/index.tsx | 8 ++------
 1 file changed, 2 insertions(+), 6 deletions(-)

diff --git a/superset-frontend/src/SqlLab/components/HighlightedSql/index.tsx b/superset-frontend/src/SqlLab/components/HighlightedSql/index.tsx
index a2ac275323d..ff53b2832e7 100644
--- a/superset-frontend/src/SqlLab/components/HighlightedSql/index.tsx
+++ b/superset-frontend/src/SqlLab/components/HighlightedSql/index.tsx
@@ -16,7 +16,7 @@
  * specific language governing permissions and limitations
  * under the License.
  */
-import { css, styled, useTheme } from '@apache-superset/core/theme';
+import { styled, useTheme } from '@apache-superset/core/theme';
 import { t } from '@apache-superset/core/translation';
 import { ModalTrigger } from '@superset-ui/core/components';
 import CodeSyntaxHighlighter from '@superset-ui/core/components/CodeSyntaxHighlighter';
@@ -81,11 +81,7 @@ function HighlightSqlModal({ rawSql, sql }: HighlightedSqlModalTypes) {
   };
 
   return (
-    <div
-      css={css`
-        margin: -${theme.sizeUnit * 6}px;
-      `}
-    >
+    <div>
       <Title>{t('Source SQL')}</Title>
       <CodeSyntaxHighlighter language="sql" customStyle={codeBlockStyle}>
         {sql}