Build a 25 5 Clock User Stories 22-23

I am working on the 25+5 clock and have it functioning correctly. However, I am failing tests 22-23 the transition from session to break timers. My timer hits 00:00 as is required in the earlier test, and after 1 second it switches both the label and sets the timer to the break length but the test is still failing. I have played with the code for a couple days now looking for a fix but have been unable to find a solution. Any help would be appreciated!

Your code so far

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/105.0.0.0 Safari/537.36

Challenge: Front End Development Libraries Projects - Build a 25 + 5 Clock

Link to the challenge:

I think codepen might be referring to that HTML section itself when it’s evaluating tests 22-23. The text under the element “time-label” may change in the console, but it doesn’t change within that HTML section.

Maybe take “Session” text from that time-label div in the HTML and input the text using the javascript instead?

As in statuslabel.innerText = variableName ?

Then do the same for the “time-left” div

2 Likes

Thanks for the reply. Even after changing all instances of innerHTML to innerText for the time-label and time-left divs it still isn’t passing the tests. it is failing the same two. I am unsure of how I can fail 22-23 but not 24-25 as they are all about starting a new countdown after reaching zero. 22-23 are switching form session to break which fail, but I pass the tests switching from break to session, but I cant find anything different between the cases.

1 Like

I don’t mean changing innerHTML to innerText.

I mean, removing the text from the time label element so it looks like this

<div id="time-label"></>

And then adding the text via javascript

I did that as well after replying and still with no luck.

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.