Pen Settings

HTML

CSS

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URL's added here will be added as <link>s in order, and before the CSS in the editor. If you link to another Pen, it will include the CSS from that Pen. If the preprocessor matches, it will attempt to combine them before processing.

+ add another resource

JavaScript

Babel includes JSX processing.

Add External Scripts/Pens

Any URL's added here will be added as <script>s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.

+ add another resource

Packages

Add Packages

Search for and use JavaScript packages from npm here. By selecting a package, an import statement will be added to the top of the JavaScript editor for this package.

Behavior

Save Automatically?

If active, Pens will autosave every 30 seconds after being saved once.

Auto-Updating Preview

If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.

Format on Save

If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.

Editor Settings

Code Indentation

Want to change your Syntax Highlighting theme, Fonts and more?

Visit your global Editor Settings.

HTML

              
                <link href="//maxcdn.bootstrapcdn.com/font-awesome/4.2.0/css/font-awesome.min.css" rel="stylesheet">

<div class="container">
  <div class="row">
    <h2 class="text-center title">Rorry's Pomodoro </h1>
  </div><!--end row for title -->
  
  <div class="row col-lg-6 col-lg-offset-3 text-center">
    <div class="pull-left ">
      <span>Work amount:</span>
      <h5 class="text-center">
        <span>&nbsp;<button id="clock1minus"><i class="fa fa-minus"></i></button></span>
        <span class="duration" id="workTime">25</span>
        <span>&nbsp;<button id="clock1plus"><i class="fa fa-plus"></i></button></span>
      </h5>
    </div><!--end work timer modifier -->
    
    <div class="pull-right">
      <span>Break amount</span>
      <h5 class="text-center">
        <span>&nbsp;<button id="clock2minus"><i class="fa fa-minus"></i></button></span>
        <span class="duration" id="breakTime">5</span>
        <span>&nbsp;<button id="clock2plus"><i class="fa fa-plus"></i></a></button>
      </h5>
    </div><!--end break timer modifier -->
  </div><!--end timers modificators row -->

  <br/>      
  
  <div class="row text-center flip-clock-wrapper">
    <span class="clock-header worktimelabel">Pomodoro</span>
    <div class="clock1"></div>

 <span class="clock-header breaktimelabel">Break</span>
    <div class="clock2"></div>
    <div class="controls">
    	 <button class="btn-success" id="startB"><i class="fa fa-play"></i></button> 
       <button class="btn-warning" id="stopB"><i class="fa fa-pause"></i></button>
       <button class="btn-danger" id="resetB"><i class="fa fa-stop"></i></button>
    </div><!--end button controls-->
  </div><!--end clock wrapper -->
</div><!--end container -->

<!-- Here goes the page footer -->
<footer class="text-center">
  <hr>
  <p>Coded by <a href="https://www.freecodecamp.com/elrodrigote" target="_blank">Rodrigo Ali</a>.</p>
</footer>  
              
            
!

CSS

              
                @import url(https://fonts.googleapis.com/css?family=Oswald);

body{
  background-color: #0d0d0d;
  color: #fff;
  font-family: Oswald;
  margin-bottom:50px;
}

footer{
  text-align: center;
  bottom:0px;
  left:0px;
  right:0px;
  margin-bottom:0px;
}

header h2{
  font-size: 40px;
  font-family: Oswald; 
  font-weight: bold;
}

div button{
  font-size: 20px;
  color: #000;
}

.duration{
    font-family: Orbitron;
}

.clock1{
  margin-left: 0px auto;
  color: #FFF;!important
  /* max-width: 300px; */
}

.flip-clock-wrapper{
  max-width: 300px !important;
  height: auto !important;
  margin: 0 auto!important;
  display: block;
}

.flip-clock-label{
color: #FFF !important;
}

.clock-header {
    font-family: Orbitron, sans-serif;
     font-size: 40px;
     padding-bottom: 10px!important;
     text-align: center;
     display: inline-block;
}

.controls{
  display: inline-block;
  margin-top: 10px;
  margin-bottom: 10px;
}
              
            
!

JS

              
                $(document).ready(function(){
  
  $("button").addClass("btn");
 
  var workClock;
  var breakClock;
  var workTime;
  var breakTime;
  
  workTime = parseInt($("#workTime").html() * 60);
  breakTime = parseInt($("#breakTime").html() * 60);
  

  workClock = $('.clock1').FlipClock(workTime,{
		       clockFace: "MinuteCounter",
           autoStart: false,
           countdown: true,
           callbacks: {
            start: function(){
              $(".worktimelabel").addClass("text-success");
            },
             
            stop: function(){
              $(".worktimelabel").removeClass("text-success");
            },
        
            interval: function(){
              var time = workClock.getTime().time;
              if(time === 0){
                breakClock.setTime(parseInt($("#breakTime").html() * 60));
                breakClock.start();
              }//end interval's if
            }//end interval
          }//end callbacks
				});//end workClock
  

breakClock = $('.clock2').FlipClock(breakTime,{
           clockFace: "MinuteCounter",
           autoStart: false,
           countdown: true,
           callbacks: {
             start: function(){
              $(".breaktimelabel").addClass("text-danger");
             },
             
             stop: function(){
              $(".breaktimelabel").removeClass("text-danger");
             },
             
             interval: function(){
              var time2 = breakClock.getTime().time;
              if(time2 === 0){
              workClock.setTime(parseInt($("#workTime").html() * 60));
              workClock.start();
              }//end interval's if
            }//end interval
          }//end callbacks
        });//end breakClock
  
  $("#startB").click(function(){
    workClock.setTime(parseInt($("#workTime").html() * 60));
    breakClock.setTime(parseInt($("#breakTime").html() * 60));
    workClock.start();
  })

  $("#stopB").click(function(){
    workClock.stop();
    breakClock.stop();
  })

  $("#resetB").click(function(){
    workClock.setTime(parseInt($("#workTime").html() * 60));
    breakClock.setTime(parseInt($("#breakTime").html() * 60));
    breakClock.stop();
    workClock.stop();
  });

  $("#clock1plus").click(function(){
    workTime = parseInt($("#workTime").html());
    $("#workTime").html(workTime + 1);
    workClock.setTime(parseInt($("#workTime").html()) * 60);
  });

  $("#clock1minus").click(function(){
    workTime = parseInt($("#workTime").html());
    $("#workTime").html(workTime - 1);
    if(workTime === 1){
      $("#workTime").html(1);
    }
    workClock.setTime(parseInt($("#workTime").html()) * 60);
  });
  
  $("#clock2plus").click(function(){
    breakTime = parseInt($("#breakTime").html());
    $("#breakTime").html(breakTime + 1);
    breakClock.setTime(parseInt($("#breakTime").html()) * 60);
  });
  
  $("#clock2minus").click(function(){
    breakTime = parseInt($("#breakTime").html());
    $("#breakTime").html(breakTime - 1);
    if(breakTime === 1){
      $("#breakTime").html(1);
    }
    breakClock.setTime(parseInt($("#breakTime").html()) * 60);
  });

});//end document ready
              
            
!
999px

Console