bito-code-review[bot] commented on code in PR #41079:
URL: https://github.com/apache/superset/pull/41079#discussion_r3477696130


##########
superset-frontend/src/dashboard/components/DashboardGrid.tsx:
##########
@@ -170,16 +187,21 @@ class DashboardGrid extends PureComponent<
   handleResizeStart(): void {
     this.setState(() => ({
       isResizing: true,
+      rowGuideTop: null,
     }));
   }
 
   handleResize(
     _event: MouseEvent | TouchEvent,
-    _direction: string,
-    _elementRef: HTMLElement,
+    direction: string,
+    elementRef: HTMLElement,
     _delta: { width: number; height: number },
   ): void {
-    // no-op: resize position is tracked via getRowGuidePosition
+    if (direction.toLowerCase().includes('bottom')) {
+      this.setState(() => ({
+        rowGuideTop: this.getRowGuidePosition(elementRef),
+      }));
+    }

Review Comment:
   <div>
   
   
   <div id="suggestion">
   <div id="issue"><b>Missing test coverage for row guide</b></div>
   <div id="fix">
   
   The mock DashboardComponent in `DashboardGrid.test.tsx` doesn't include the 
`onResize` callback with its `direction` parameter that this change introduces. 
Tests won't exercise the new row-guide logic. Add `onResize` to the mock and a 
test case verifying `.grid-row-guide` renders when resizing from the bottom.
   </div>
   
   
   </div>
   
   
   
   
   <small><i>Code Review Run #a7c3b2</i></small>
   </div>
   
   ---
   Should Bito avoid suggestions like this for future reviews? (<a 
href=https://alpha.bito.ai/home/ai-agents/review-rules>Manage Rules</a>)
   - [ ] Yes, avoid them



-- 
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