bugfix: make dragging track to bottom of list work reliably
Hunter
Wednesday, May 6th, 2026 at 5:48 PM
121 r.item.style.top = `${rect.top}px`;
122 r.item.style.width = `${playlistRect.width}px`;
123 r.item.style.height = `${rect.height}px`;
- r.item.style.zIndex = '10';
124 + r.item.style.zIndex = '3';
125 document.body.appendChild(r.item);
126 // Now we're actually dragging — disable pointer-events on the other items
127 document.body.classList.add('reordering');
167 const controlsRect = controls.getBoundingClientRect();
168 const desiredTop = r.lastClientY - r.offsetY;
169 const minTop = wrapperRect.top;
- const maxTop = controlsRect.top - r.itemHeight;
170 + const maxTop = controlsRect.top - r.itemHeight / 2;
171 const clampedTop = Math.max(minTop, Math.min(maxTop, desiredTop));
172 r.item.style.top = `${clampedTop}px`;
173
75 left: 0;
76 right: 0;
77 box-sizing: border-box;
- z-index: 3;
78 + z-index: 4;
79 pointer-events: none;
80 }
81