Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Background
Starts PLAT-430. Previously, #37384 moved the
sectionMetrics
state up toActivitiesEditor
and made sure to update so that dragging would work when the page was scrolled before dragging starts. This PR deals with a related problem of making sure that dragging will work when scrolling happens after dragging starts.This PR tackles two specific problems:
"drop" target does not follow the cursor (I had to use a mouse with a scrollwheel to capture this behavior)
dragging doesn't cause the page to scroll
Description
Here's what this PR does:
Here is how it looks:
Future work
The following problems are tackled in the next PR:
3. the dragged element does not follow the cursor
4. the logic for reordering levels within the original activity section is broken
Testing story
Manual testing only for drag and drop behavior. Existing test coverage guards against regressions in other features within the lesson editor.
Reviewer Checklist: