Skip to content

Commit

Permalink
initial scaffolding of app
Browse files Browse the repository at this point in the history
  • Loading branch information
jeremiahadkins committed Jul 31, 2017
0 parents commit b1b4c0c
Show file tree
Hide file tree
Showing 78 changed files with 125 additions and 0 deletions.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
20 changes: 20 additions & 0 deletions css/style.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 7 additions & 0 deletions css/style.css.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

20 changes: 20 additions & 0 deletions index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
<html>
<head>
<meta charset="UTF-8">
<script
src="http://code.jquery.com/jquery-3.2.1.min.js"
integrity="sha256-hwg4gsxgFZhOsEEamdOYGBf13FyQuiTwlAQgxVSNgt4="
crossorigin="anonymous">
</script>
<link href="https://fonts.googleapis.com/css?family=Teko:500,700" rel="stylesheet">
<link rel="stylesheet" href="css/style.css">
<title>Color Clock</title>
</head>
<body>
<div class="time-bar-wrapper">
<div class="time-bar"></div>
</div>
<h1 class="current-time"></h1>
<script src="main.js"></script>
</body>
</html>
34 changes: 34 additions & 0 deletions main.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
function clock () {
// defining vars
var time = new Date();
var timeHours = time.getHours() > 12 ? time.getHours() - 12 : time.getHours();
var timeMinutes = time.getMinutes() < 10 ? "0" + time.getMinutes() : time.getMinutes();
var timeSeconds = time.getSeconds() < 10 ? "0" + time.getSeconds() : time.getSeconds();
var timeSplit = timeHours + ":" + timeMinutes + ":" + timeSeconds;

// setting time
$(".current-time").html(timeSplit);

// defining percentage
var roundedTimeSeconds = parseFloat((timeSeconds/60).toFixed(2));
var roundedTimeSecondsToInt= (roundedTimeSeconds * 100).toString();

// console log percentage
console.log(roundedTimeSecondsToInt);

// setting width = 'initial'
$(".time-bar").css("width", roundedTimeSecondsToInt + "%");

var timeToColor = function(a,b,c){
var concatTimes = a.toString() + b.toString() + c.toString();
console.log('concat times', concatTimes);
return concatTimes;
}

$('body').css("background-color", timeToColor(timeSeconds, timeMinutes, timeHours));

console.log(typeof(timeToColor(timeSeconds, timeMinutes, timeHours)));
}

// function call on timer
window.setInterval(clock, 1000);
21 changes: 21 additions & 0 deletions scss/style.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
body { margin: 0; }

.time-bar {
background-color: #fff;
height: 7px;
}

.time-bar-wrapper {
background-color: rgba(#000, .3);
height: 7px;
}

.current-time {
color: #fff;
font-family: 'Teko', sans-serif;
font-weight: 700;
font-size: 200px;
margin: 250px auto;
text-align: center;
}

23 changes: 23 additions & 0 deletions style.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
/*
Errno::ENOENT: No such file or directory @ rb_sysopen - style.scss
Backtrace:
/Users/jeremiahadkins/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/sass-3.4.23/lib/sass/plugin/compiler.rb:484:in `read'
/Users/jeremiahadkins/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/sass-3.4.23/lib/sass/plugin/compiler.rb:484:in `update_stylesheet'
/Users/jeremiahadkins/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/sass-3.4.23/lib/sass/plugin/compiler.rb:215:in `block in update_stylesheets'
/Users/jeremiahadkins/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/sass-3.4.23/lib/sass/plugin/compiler.rb:209:in `each'
/Users/jeremiahadkins/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/sass-3.4.23/lib/sass/plugin/compiler.rb:209:in `update_stylesheets'
/Users/jeremiahadkins/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/sass-3.4.23/lib/sass/plugin/compiler.rb:294:in `watch'
/Users/jeremiahadkins/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/sass-3.4.23/lib/sass/plugin.rb:109:in `method_missing'
/Users/jeremiahadkins/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/sass-3.4.23/lib/sass/exec/sass_scss.rb:360:in `watch_or_update'
/Users/jeremiahadkins/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/sass-3.4.23/lib/sass/exec/sass_scss.rb:51:in `process_result'
/Users/jeremiahadkins/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/sass-3.4.23/lib/sass/exec/base.rb:52:in `parse'
/Users/jeremiahadkins/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/sass-3.4.23/lib/sass/exec/base.rb:19:in `parse!'
/Users/jeremiahadkins/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/sass-3.4.23/bin/sass:13:in `<top (required)>'
/Users/jeremiahadkins/.rbenv/versions/2.3.1/bin/sass:23:in `load'
/Users/jeremiahadkins/.rbenv/versions/2.3.1/bin/sass:23:in `<main>'
*/
body:before {
white-space: pre;
font-family: monospace;
content: "Errno::ENOENT: No such file or directory @ rb_sysopen - style.scss"; }

0 comments on commit b1b4c0c

Please sign in to comment.