Skip to content

Commit

Permalink
Rotation Drag: Make only the hamburger icon a drag handle
Browse files Browse the repository at this point in the history
Only the icon should allow the drag, not the entire .rotation-name element
  • Loading branch information
sukhwinder33445 committed Mar 3, 2025
1 parent bc5314a commit 928d2a2
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
9 changes: 5 additions & 4 deletions public/css/timeline.less
Original file line number Diff line number Diff line change
Expand Up @@ -80,13 +80,14 @@
.rotation-name {
font-size: 1.25em;
font-weight: bold;
cursor: grab;

[data-drag-initiator] {
color: @gray-light;
}
&:hover [data-drag-initiator] {
color: @text-color;

&:hover {
cursor: grab;
color: @list-item-title-hover-color;
}
}

// :not(:empty) is only necessary to increase specificity
Expand Down
3 changes: 2 additions & 1 deletion public/js/schedule.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,8 @@
Sortable.create(sideBar, {
scroll: true,
direction: 'vertical',
draggable: '.rotation-name'
draggable: '.rotation-name',
handle: '.rotation-name > i[data-drag-initiator]'
});
}

Expand Down

0 comments on commit 928d2a2

Please sign in to comment.