Skip to content

Commit

Permalink
Update syllabussite.js
Browse files Browse the repository at this point in the history
  • Loading branch information
elproffesore authored Feb 27, 2024
1 parent 4bda850 commit eca9077
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/syllabussite.js
Original file line number Diff line number Diff line change
Expand Up @@ -219,8 +219,8 @@ function update() {
function updateCursor(session, sessionProgress) {
let cursorDimensions = session.cursor.getBoundingClientRect();
let cursorPosition = session.index === 0
? (window.outerHeight / 2) - (sessionProgress * (window.outerHeight / 2)) - (sessionProgress * (cursorDimensions.height * 1.5))
: window.outerHeight - (sessionProgress * window.outerHeight) - (sessionProgress * (cursorDimensions.height * 1.5))
? (window.outerHeight * 0.25) - (sessionProgress * (window.outerHeight * 0.25)) - (sessionProgress * (cursorDimensions.height))
: window.outerHeight - (sessionProgress * window.outerHeight) - (sessionProgress * (cursorDimensions.height))
session.cursor.style.top = `${cursorPosition}px`;
return [cursorPosition, cursorDimensions.height];
}
Expand Down Expand Up @@ -378,4 +378,4 @@ function resized() {
lastWidth = window.outerWidth;
}

window.onresize = resized;
window.onresize = resized;

0 comments on commit eca9077

Please sign in to comment.