codeant-ai-for-open-source[bot] commented on code in PR #39257:
URL: https://github.com/apache/superset/pull/39257#discussion_r3658133006


##########
superset-frontend/src/components/Datasource/components/DatasourceEditor/DatasourceEditor.tsx:
##########
@@ -2240,6 +2295,8 @@ function DatasourceEditor({
             expression: '',
           })}
           itemCellProps={{
+            metric_name: () => ({ className: 'datasource-key-cell' }),
+            verbose_name: () => ({ className: 'datasource-label-cell' }),
             expression: () => ({

Review Comment:
   **Suggestion:** The new wide layout does not actually remove the existing 
inline `maxWidth: 240px` constraint from the Metrics expression cell. Because 
that inline style has higher precedence than the stylesheet, the SQL expression 
field remains capped at 240px despite the new 50%/480px sizing rules. Remove or 
update the inline maximum when applying the wide layout. [logic error]
   
   <details>
   <summary><b>Severity Level:</b> Major ⚠️</summary>
   
   ```mdx
   - ⚠️ Metrics SQL expressions remain narrow despite the wide layout.
   - ⚠️ Long metric expressions require more scrolling or horizontal 
interaction.
   - ⚠️ The Metrics tab does not receive the intended usability improvement.
   ```
   </details>
   <details>
   <summary><b>Steps of Reproduction ✅ </b></summary>
   
   ```mdx
   1. Open the dataset editor, which renders the Metrics tab from 
`DatasourceEditor` in
   
`superset-frontend/src/components/Datasource/components/DatasourceEditor/DatasourceEditor.tsx:2429-2437`.
   
   2. Select the Metrics tab so `renderMetricCollection()` renders the metrics 
table at
   `DatasourceEditor.tsx:2435-2436`.
   
   3. Inspect a metric expression cell configured by 
`DatasourceEditor.tsx:2300-2305`; its
   inline style sets `maxWidth: '240px'` and `overflow: 'hidden'`.
   
   4. The surrounding `wide-sql-layout` applies a 50% width and `min-width: 
480px` at
   `DatasourceEditor.tsx:405-408`, but its stylesheet `max-width: none` cannot 
override the
   inline `maxWidth: 240px`; the SQL editor therefore remains visually capped at
   approximately 240px instead of using the expanded layout.
   ```
   </details>
   
   [![Fix in 
Cursor](https://new-codeant-butcket.s3.us-west-1.amazonaws.com/badges/fix-in-cursor-flat.svg)](https://app.codeant.ai/fix-in-ide?tool=cursor&prompt_id=24d3d1a3b72f4075bc9a8f8c30862eae&service=github&base_url=https%3A%2F%2Fgithub.com&org=apache&repo=apache%2Fsuperset)
 [![Fix in VSCode 
Claude](https://new-codeant-butcket.s3.us-west-1.amazonaws.com/badges/fix-in-vscode-claude-flat.svg)](https://app.codeant.ai/fix-in-ide?tool=vscode-claude&prompt_id=24d3d1a3b72f4075bc9a8f8c30862eae&service=github&base_url=https%3A%2F%2Fgithub.com&org=apache&repo=apache%2Fsuperset)
   
   *(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/src/components/Datasource/components/DatasourceEditor/DatasourceEditor.tsx
   **Line:** 2300:2305
   **Comment:**
        *Logic Error: The new wide layout does not actually remove the existing 
inline `maxWidth: 240px` constraint from the Metrics expression cell. Because 
that inline style has higher precedence than the stylesheet, the SQL expression 
field remains capped at 240px despite the new 50%/480px sizing rules. Remove or 
update the inline maximum when applying the wide layout.
   
   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%2F39257&comment_hash=6d8ca407d801d4f5d5fe39171fc315a643eea15de8ad7ca47e469d7daa3592bc&reaction=like'>👍</a>
 | <a 
href='https://app.codeant.ai/feedback?pr_url=https%3A%2F%2Fgithub.com%2Fapache%2Fsuperset%2Fpull%2F39257&comment_hash=6d8ca407d801d4f5d5fe39171fc315a643eea15de8ad7ca47e469d7daa3592bc&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]

Reply via email to