Skip to content

Commit

Permalink
abi: made funcs to move between pages
Browse files Browse the repository at this point in the history
  • Loading branch information
AndyHubert committed Jul 23, 2024
1 parent 9a014a0 commit 0f892fe
Showing 1 changed file with 39 additions and 4 deletions.
43 changes: 39 additions & 4 deletions abi/main.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,44 @@
// document.querySelector('#stick-figure').innerHTML = ""
// document.querySelector('#view-log').addEventListener('click', () => {

// })
// document.querySelector('#screen-buttons').classList.add('hide')
let startWorkoutFunction = () => {
document.querySelector('#screen-buttons').classList.add('hide')
document.querySelector('#screen-workout').classList.remove('hide')
}

document.querySelector('#do-legs').addEventListener('click',
() => {
startWorkoutFunction()
}
)
document.querySelector('#do-arms').addEventListener('click',
() => {
startWorkoutFunction()
}
)
document.querySelector('#do-random').addEventListener('click',
() => {
startWorkoutFunction()
}
)
document.querySelector('#cancel').addEventListener('click',
() => {
document.querySelector('#screen-workout').classList.add('hide')
document.querySelector('#screen-buttons').classList.remove('hide')
}
)
document.querySelector('#view-log').addEventListener('click',
() => {
document.querySelector('#screen-buttons').classList.add('hide')
document.querySelector('#screen-log').classList.remove('hide')
}
)
document.querySelector('#back').addEventListener('click',
() => {
document.querySelector('#screen-log').classList.add('hide')
document.querySelector('#screen-buttons').classList.remove('hide')
}
)

// document.querySelector('#stick-figure').innerHTML = ""

// Things my program needs to do:
// if buttin is pushed start the workout chosen
Expand Down

0 comments on commit 0f892fe

Please sign in to comment.