This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| "use strict"; | |
| class Color { | |
| constructor(r, g, b) { | |
| this.set(r, g, b); | |
| } | |
| toString() { | |
| return `rgb(${Math.round(this.r)}, ${Math.round(this.g)}, ${Math.round( | |
| this.b | |
| )})`; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // iMacro CheatSheet - Command Reference | |
| // http://wiki.imacros.net/Command_Reference | |
| // iMacros supports 3 types of variables: | |
| // * The macro variables !VAR0 thru !VAR9. They can be used with the SET and ADD command inside a macro. | |
| // * Built-in variables. They contain certain values set by iMacros. | |
| // * User-defined variables. They are defined in-macro using the SET command. | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!DOCTYPE html> | |
| <html> | |
| <head> | |
| <script src="http://code.jquery.com/jquery-latest.min.js"></script> | |
| <script src="realtime.js"></script> | |
| <style type="text/css"> | |
| #chat { | |
| width:300px; | |
| height:300px; | |
| border:1px solid black; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Ajax File upload with jQuery and XHR2 | |
| // Sean Clark http://square-bracket.com | |
| // xhr2 file upload | |
| $.fn.upload = function(remote, data, successFn, progressFn) { | |
| // if we dont have post data, move it along | |
| if (typeof data != "object") { | |
| progressFn = successFn; | |
| successFn = data; | |
| } |