File tree Expand file tree Collapse file tree 2 files changed +5
-5
lines changed
docs/2-browser-apps/03-class Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Original file line number Diff line number Diff line change 11const countdownBox = document . getElementById ( "countdown-box" ) ;
22
33const now = new Date ( ) ;
4- const remainingHours = 24 - now . getHours ( ) ;
5- const remainingMinutes = 60 - now . getMinutes ( ) ;
4+ const remainingHours = 23 - now . getHours ( ) ;
5+ const remainingMinutes = 59 - now . getMinutes ( ) ;
66const remainingSeconds = 60 - now . getSeconds ( ) ;
7- countdownBox . textContent = `今日は残り${ remainingHours } 時間 ${ remainingMinutes } 分 ${ remainingSeconds } 秒です。` ;
7+ countdownBox . textContent = `今日は残り${ remainingHours } 時間 ${ remainingMinutes } 分 ${ remainingSeconds } 秒です。` ;
Original file line number Diff line number Diff line change @@ -396,8 +396,8 @@ document.write(false.toString()); // false
396396const countdownBox = document .getElementById (" countdown-box" );
397397
398398const now = new Date ();
399- const remainingHours = 24 - now .getHours ();
400- const remainingMinutes = 60 - now .getMinutes ();
399+ const remainingHours = 23 - now .getHours ();
400+ const remainingMinutes = 59 - now .getMinutes ();
401401const remainingSeconds = 60 - now .getSeconds ();
402402countdownBox .textContent = ` 今日は残り${ remainingHours} 時間 ${ remainingMinutes} 分 ${ remainingSeconds} 秒です。` ;
403403```
You can’t perform that action at this time.
0 commit comments