Merge pull request #85 from Git-Lior/scroll-fix

bug fix: scrolling on CommitList scrolls the page as well
This commit is contained in:
Rodrigo Pombo 2019-02-13 17:28:22 -03:00 committed by GitHub
commit c4cd1f198e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -68,6 +68,7 @@ function CommitInfo({ commit, move, onClick }) {
function CommitList({ commits, currentIndex, selectCommit }) {
const mouseWheelEvent = e => {
e.preventDefault();
selectCommit(currentIndex + (e.deltaX + e.deltaY) / 100);
};
return (