File tree Expand file tree Collapse file tree 2 files changed +11
-6
lines changed
code/Magento/Ui/view/base/web/js/dynamic-rows
design/adminhtml/Magento/backend/web/css/source/forms/fields Expand file tree Collapse file tree 2 files changed +11
-6
lines changed Original file line number Diff line number Diff line change @@ -183,9 +183,13 @@ define([
183
183
/**
184
184
* Mouse up handler
185
185
*/
186
- mouseupHandler : function ( ) {
186
+ mouseupHandler : function ( event ) {
187
187
var depElementCtx ,
188
- drEl = this . draggableElement ;
188
+ drEl = this . draggableElement ,
189
+ pageY = isTouchDevice ? event . originalEvent . touches [ 0 ] . pageY : event . pageY ,
190
+ positionY = pageY - drEl . eventMousedownY ;
191
+
192
+ drEl . depElement = this . getDepElement ( drEl . instance , positionY ) ;
189
193
190
194
if ( drEl . depElement ) {
191
195
depElementCtx = this . getRecord ( drEl . depElement . elem [ 0 ] ) ;
@@ -272,12 +276,12 @@ define([
272
276
rec = collection . eq ( i ) ;
273
277
274
278
if ( position === 'before' ) {
275
- rangeStart = collection . eq ( i ) . position ( ) . top ;
276
- rangeEnd = rangeStart + this . step ;
279
+ rangeStart = collection . eq ( i ) . position ( ) . top - this . step ;
280
+ rangeEnd = rangeStart + this . step * 2 ;
277
281
className = this . separatorsClass . top ;
278
282
} else if ( position === 'after' ) {
279
- rangeEnd = rec . position ( ) . top + rec . height ( ) ;
280
- rangeStart = rangeEnd - this . step ;
283
+ rangeEnd = rec . position ( ) . top + rec . height ( ) + this . step ;
284
+ rangeStart = rangeEnd - this . step * 2 ;
281
285
className = this . separatorsClass . bottom ;
282
286
}
283
287
Original file line number Diff line number Diff line change 205
205
206
206
.admin__dynamic-rows {
207
207
& ._dragged {
208
+ opacity : .95 ;
208
209
position : absolute ;
209
210
z-index : 999 ;
210
211
}
You can’t perform that action at this time.
0 commit comments