Skip to content

Conversation

@saff-coder
Copy link

Learners, PR Template

Self checklist

  • I have titled my PR with Region | Cohort | FirstName LastName | Sprint | Assignment Title
  • My changes meet the requirements of the task
  • I have tested my changes
  • My changes follow the style guide

Changelist

Wrote the countdown logic.
Updated the timer display.
Made the alarm play at 00:00.
Added pause/resume button.
Added flashing background.

Questions

No questions

@saff-coder saff-coder added the Needs Review Trainee to add when requesting review. PRs without this label will not be reviewed. label Nov 22, 2025
@jaymes15 jaymes15 self-requested a review November 23, 2025 15:02
@jaymes15 jaymes15 added Review in progress This review is currently being reviewed. This label will be replaced by "Reviewed" soon. and removed Needs Review Trainee to add when requesting review. PRs without this label will not be reviewed. labels Nov 23, 2025
// Update the text at the top: "Time Remaining: mm:ss"
function updateTimeDisplay() {
const titleElement = document.getElementById("timeRemaining");
if (!titleElement) return; // safety check

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good defensive programming

if (!input) return;

const seconds = Number(input.value);
document.body.style.backgroundColor = "red";

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove or move the red background line.
It probably belongs inside the block that runs when the countdown reaches zero.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the suggestion!
I’ve moved the red background line into the block that runs when the countdown reaches zero, so it only turns red when the timer finishes instead of immediately.

@jaymes15 jaymes15 added 📅 Sprint 3 Assigned during Sprint 3 of this module Reviewed Volunteer to add when completing a review with trainee action still to take. and removed Review in progress This review is currently being reviewed. This label will be replaced by "Reviewed" soon. labels Nov 23, 2025
@saff-coder saff-coder requested a review from jaymes15 November 23, 2025 16:42
@saff-coder saff-coder changed the title London | 25-ITP-May | Sophia Mohamed| Sprint 3 | Alarm Clock London | 25-ITP-Sep | Sophia Mohamed| Sprint 3 | Alarm Clock Nov 23, 2025
@jaymes15 jaymes15 added Complete Volunteer to add when work is complete and all review comments have been addressed. and removed Reviewed Volunteer to add when completing a review with trainee action still to take. labels Nov 23, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Complete Volunteer to add when work is complete and all review comments have been addressed. 📅 Sprint 3 Assigned during Sprint 3 of this module

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants