Skip to content

London | 26-ITP-Sept | Fung Nin Lee | Sprint 3 | Alarm Clock - #1579

Open
leerogerfn wants to merge 1 commit into
CodeYourFuture:mainfrom
leerogerfn:sprint-3/alarm-clock
Open

leerogerfn wants to merge 1 commit into
CodeYourFuture:mainfrom
leerogerfn:sprint-3/alarm-clock

Conversation

@leerogerfn

Copy link
Copy Markdown

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

Task code

CYF-1098

Changelist

Implemented the function of alarm clock.

@leerogerfn leerogerfn added 📅 Sprint 3 Assigned during Sprint 3 of this module Needs Review Trainee to add when requesting review. PRs without this label will not be reviewed. Module-Data-Groups The name of the module. labels Nov 23, 2026
Comment on lines +23 to +31
const countdownId = setInterval(() => {
numberForTime -= 1;
updateDisplay(numberForTime);

if (numberForTime <= 0) {
clearInterval(countdownId);
playAlarm();
}
}, 1000);

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

If Set Alarm is clicked again before this interval finishes, what happens to the countdown created here?

To "like" or "dislike" this comment, please follow this link

Comment on lines +5 to +7
if (numberForTime <= 0 || Number.isInteger(numberForTime) === false) {
return (document.getElementById("reminder").textContent =
"Value of time should be more than '0'.");

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

What message does a user see after entering a positive fractional value, and does it explain why that value was rejected?

To "like" or "dislike" this comment, please follow this link

@cyf-ai-code-reviewer cyf-ai-code-reviewer Bot added Reviewed Volunteer to add when completing a review with trainee action still to take. and removed Needs Review Trainee to add when requesting review. PRs without this label will not be reviewed. labels Nov 23, 2026
@cyf-ai-code-reviewer

Copy link
Copy Markdown

The CYF AI review has left comments. It will only review a PR one time. When you have addressed these comments, please request review again and a volunteer will take a look.

@leerogerfn leerogerfn added Needs Review Trainee to add when requesting review. PRs without this label will not be reviewed. and removed Reviewed Volunteer to add when completing a review with trainee action still to take. labels Nov 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Module-Data-Groups The name of the module. Needs Review Trainee to add when requesting review. PRs without this label will not be reviewed. 📅 Sprint 3 Assigned during Sprint 3 of this module

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant