File tree Expand file tree Collapse file tree
hierarchical-grid/row-drag-base/src
tree-grid/row-drag-base/src Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -27,7 +27,7 @@ export default function App() {
2727 const ghostElement = evt . detail . dragDirective . ghostElement ;
2828 if ( ghostElement != null ) {
2929 const dragElementPos = ghostElement . getBoundingClientRect ( ) ;
30- const gridPosition = document . getElementById ( "hierarchicalGrid2" ) . getBoundingClientRect ( ) ;
30+ const gridPosition = document . getElementById ( "hierarchicalGrid2" ) . getElementsByTagName ( "igc-hierarchical-grid" ) [ 0 ] . getBoundingClientRect ( ) ;
3131
3232 const withinXBounds = dragElementPos . x >= gridPosition . x && dragElementPos . x <= gridPosition . x + gridPosition . width ;
3333 const withinYBounds = dragElementPos . y >= gridPosition . y && dragElementPos . y <= gridPosition . y + gridPosition . height ;
Original file line number Diff line number Diff line change @@ -36,7 +36,7 @@ export default function App() {
3636 const ghostElement = evt . detail . dragDirective . ghostElement ;
3737 if ( ghostElement != null ) {
3838 const dragElementPos = ghostElement . getBoundingClientRect ( ) ;
39- const gridPosition = document . getElementById ( "treeGrid2" ) . getBoundingClientRect ( ) ;
39+ const gridPosition = document . getElementById ( "treeGrid2" ) . getElementsByTagName ( "igc-tree-grid" ) [ 0 ] . getBoundingClientRect ( ) ;
4040
4141 const withinXBounds = dragElementPos . x >= gridPosition . x && dragElementPos . x <= gridPosition . x + gridPosition . width ;
4242 const withinYBounds = dragElementPos . y >= gridPosition . y && dragElementPos . y <= gridPosition . y + gridPosition . height ;
You can’t perform that action at this time.
0 commit comments