diff --git a/superset-frontend/src/dashboard/components/dnd/DragDroppable.jsx b/superset-frontend/src/dashboard/components/dnd/DragDroppable.jsx index 554efe1e99..c2d5d21dc1 100644 --- a/superset-frontend/src/dashboard/components/dnd/DragDroppable.jsx +++ b/superset-frontend/src/dashboard/components/dnd/DragDroppable.jsx @@ -141,16 +141,7 @@ export class UnwrappedDragDroppable extends PureComponent { dropIndicator !== prevState.dropIndicator || isDraggingOver !== prevProps.isDraggingOver || index !== prevProps.index; - // console.log( - // 'index', - // index, - // 'isTabsType:', - // isTabsType, - // 'component:', - // component, - // 'validStateChange:', - // validStateChange, - // ); + if (onDropIndicatorChange && isTabsType && validStateChange) { onDropIndicatorChange({ dropIndicator, isDraggingOver, index }); } diff --git a/superset-frontend/src/dashboard/components/gridComponents/Tab.jsx b/superset-frontend/src/dashboard/components/gridComponents/Tab.jsx index b70ebe1236..f99a158f9a 100644 --- a/superset-frontend/src/dashboard/components/gridComponents/Tab.jsx +++ b/superset-frontend/src/dashboard/components/gridComponents/Tab.jsx @@ -89,19 +89,6 @@ const TabTitleContainer = styled.div` `} `; -// .drop-indicator { -// display: block; -// background-color: ${theme.colors.primary.base}; -// position: absolute; -// z-index: 10; -// opacity: 0.3; -// width: 100%; -// height: 100%; -// &.drop-indicator--forbidden { -// background-color: ${theme.colors.error.light1}; -// } -// } - const TitleDropIndicator = styled.div` &.drop-indicator { position: absolute; @@ -121,7 +108,6 @@ class Tab extends PureComponent { this.handleOnHover = this.handleOnHover.bind(this); this.handleTopDropTargetDrop = this.handleTopDropTargetDrop.bind(this); this.handleChangeTab = this.handleChangeTab.bind(this); - this.logDropIndicator = this.logDropIndicator.bind(this); // this.handleGetDropPosition = this.handleGetDropPosition.bind(this); } @@ -150,22 +136,9 @@ class Tab extends PureComponent { } handleOnHover() { - // this.logDropIndicator(dropIndicatorProps); this.props.onHoverTab(); } - logDropIndicator(dropIndicatorProps) { - if (dropIndicatorProps?.dropIndicator) { - // eslint-disable-next-line no-console - console.log('dropIndicatorProps:', dropIndicatorProps); - // this.setState({ dropPosition: dropIndicatorProps.dropIndicator}); - } - } - - // handleGetDropPosition(dropIndicator, isDraggingOver) { - // this.props.onDropPositionChange(dropIndicator, isDraggingOver); - // } - handleTopDropTargetDrop(dropResult) { if (dropResult) { this.props.handleComponentDrop({