Fix regression: reset touch-item if not in /unread

This commit is contained in:
Jacob Duba 2022-01-27 21:39:35 -06:00 committed by GitHub
parent 21bbaf2691
commit 7a1429bcc1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 5 additions and 2 deletions

View File

@ -75,10 +75,13 @@ class TouchHandler {
if (distance > 75) {
toggleEntryStatus(this.touch.element);
} else {
}
// If not on the unread page, undo transform of the dragged element.
if (document.URL.split("/").indexOf("unread") == -1 || distance <= 75) {
this.touch.element.style.opacity = 1;
this.touch.element.style.transform = "none";
}
}
}
this.reset();