@@ -435,6 +435,7 @@ export default class Preview extends PreviewCollection {
435
435
436
436
/**
437
437
* Init the drop placeholder
438
+ * @deprecated - dropPlaceholder functionality moved to column-line
438
439
*
439
440
* @param {Element } element
440
441
*/
@@ -544,7 +545,6 @@ export default class Preview extends PreviewCollection {
544
545
545
546
removeDragColumn ( ) ;
546
547
547
- this . dropPlaceholder . removeClass ( "left right" ) ;
548
548
this . movePlaceholder . removeClass ( "active" ) ;
549
549
this . startDragEvent = null ;
550
550
@@ -651,7 +651,6 @@ export default class Preview extends PreviewCollection {
651
651
// Change the cursor back
652
652
$ ( "body" ) . css ( "cursor" , "" ) ;
653
653
654
- this . dropPlaceholder . removeClass ( "left right" ) ;
655
654
this . movePlaceholder . css ( "left" , "" ) . removeClass ( "active" ) ;
656
655
this . resizeGhost . removeClass ( "active" ) ;
657
656
@@ -687,7 +686,6 @@ export default class Preview extends PreviewCollection {
687
686
intersects = false ;
688
687
this . groupPositionCache = null ;
689
688
this . dropPosition = null ;
690
- this . dropPlaceholder . removeClass ( "left right" ) ;
691
689
this . movePlaceholder . css ( "left" , "" ) . removeClass ( "active" ) ;
692
690
}
693
691
} ) . on ( "mouseup touchend" , ( ) => {
@@ -926,7 +924,6 @@ export default class Preview extends PreviewCollection {
926
924
}
927
925
928
926
if ( this . movePosition ) {
929
- this . dropPlaceholder . removeClass ( "left right" ) ;
930
927
this . movePlaceholder . css ( {
931
928
left : ( this . movePosition . placement === "left" ? this . movePosition . left : "" ) ,
932
929
right : ( this . movePosition . placement === "right"
@@ -945,15 +942,6 @@ export default class Preview extends PreviewCollection {
945
942
if ( this . movePosition ) {
946
943
const classToRemove = ( this . movePosition . placement === "left" ? "right" : "left" ) ;
947
944
this . movePlaceholder . removeClass ( "active" ) ;
948
- this . dropPlaceholder . removeClass ( classToRemove ) . css ( {
949
- left : ( this . movePosition . placement === "left" ? this . movePosition . left : "" ) ,
950
- right : ( this . movePosition . placement === "right" ?
951
- groupPosition . width - this . movePosition . right : ""
952
- ) ,
953
- width : groupPosition . width / this . resizeUtils . getGridSize ( ) + "px" ,
954
- } ) . addClass ( this . movePosition . placement ) ;
955
- } else {
956
- this . dropPlaceholder . removeClass ( "left right" ) ;
957
945
}
958
946
}
959
947
}
@@ -985,21 +973,12 @@ export default class Preview extends PreviewCollection {
985
973
return currentX > position . left && currentX <= position . right && position . canShrink ;
986
974
} ) ;
987
975
988
- if ( this . dropPosition ) {
989
- this . dropPlaceholder . removeClass ( "left right" ) . css ( {
990
- left : ( this . dropPosition . placement === "left" ? this . dropPosition . left : "" ) ,
991
- right :
992
- ( this . dropPosition . placement === "right" ? groupPosition . width - this . dropPosition . right : "" ) ,
993
- width : groupPosition . width / this . resizeUtils . getGridSize ( ) + "px" ,
994
- } ) . addClass ( this . dropPosition . placement ) ;
995
- }
996
976
} else if ( this . dropOverElement ) {
997
977
// Re-enable the column group sortable instance
998
978
if ( elementChildrenParent . data ( "ui-sortable" ) ) {
999
979
elementChildrenParent . sortable ( "option" , "disabled" , false ) ;
1000
980
}
1001
981
this . dropPosition = null ;
1002
- this . dropPlaceholder . removeClass ( "left right" ) ;
1003
982
}
1004
983
}
1005
984
@@ -1015,7 +994,6 @@ export default class Preview extends PreviewCollection {
1015
994
group . droppable ( {
1016
995
deactivate ( ) {
1017
996
self . dropOverElement = null ;
1018
- self . dropPlaceholder . removeClass ( "left right" ) ;
1019
997
1020
998
_ . defer ( ( ) => {
1021
999
// Re-enable the column group sortable instance & all children sortable instances
@@ -1053,20 +1031,14 @@ export default class Preview extends PreviewCollection {
1053
1031
} ,
1054
1032
drop ( ) {
1055
1033
self . dropPositions = [ ] ;
1056
- self . dropPlaceholder . removeClass ( "left right" ) ;
1057
1034
} ,
1058
1035
out ( ) {
1059
1036
self . dropOverElement = null ;
1060
- self . dropPlaceholder . removeClass ( "left right" ) ;
1061
1037
} ,
1062
1038
over ( ) {
1063
1039
// Is the element currently being dragged a column group?
1064
1040
if ( getDraggedContentTypeConfig ( ) === Config . getContentTypeConfig ( "column-group" ) ) {
1065
1041
// Always calculate drop positions when an element is dragged over
1066
- self . dropPositions = calculateDropPositions (
1067
- self . contentType as ContentTypeCollectionInterface < ColumnGroupPreview > ,
1068
- ) ;
1069
-
1070
1042
self . dropOverElement = true ;
1071
1043
} else {
1072
1044
self . dropOverElement = null ;
0 commit comments