Skip to content

Commit

Permalink
Styling changes.
Browse files Browse the repository at this point in the history
  • Loading branch information
Izaak Schroeder committed Feb 28, 2014
1 parent b694dea commit e14d7a7
Show file tree
Hide file tree
Showing 5 changed files with 622 additions and 13 deletions.
32 changes: 29 additions & 3 deletions assets/scripts/assignment.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,33 @@

require(['jquery', 'fuzzy-time'], function($) {
requirejs.config({
paths: {
'sockjs': [ 'http://cdn.sockjs.org/sockjs-0.3.min' ]
}
})

require(['jquery', 'fuzzy-time', 'spinner', 'sockjs', 'event-emitter', 'util'], function($, fz, Spinner, SockJS, EventEmitter, util) {
//alert('assignment 4 lol!')


function IO(opts) {
EventEmitter.call(this);
//var path = window.location.protocol+'//'+window.location.host+'/io';
var path = '/io';
this.socket = new SockJS(path);
this.socket.onopen = function() {
console.log('OPEN')
}
this.socket.onmessage = function() {
console.log('MESSAGE')
}
this.socket.onclose = function() {
console.log('CLOSE')
}
}
util.inherits(IO, EventEmitter);

var io = new IO();


$(function() {
$('.assignment').on('click', '.section-collapse', function() {
$(this).closest('section').toggleClass('collapsed');
Expand Down Expand Up @@ -42,6 +68,6 @@ require(['jquery', 'fuzzy-time'], function($) {


$(this).html((score*100).toFixed(2)+'%' + ' - ' + letterGrades[entries[i]]);
})
});
})
});
Loading

0 comments on commit e14d7a7

Please sign in to comment.