made with requirebin
-
-
Save jlord/8afe42d4c26041ff1805 to your computer and use it in GitHub Desktop.
requirebin sketch
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
var langs = { | |
"ATS": { | |
"type": "programming", | |
"color": "#1ac620", | |
"lexer": "OCaml", | |
"aliases": [ | |
"ats2" | |
], | |
"extensions": [ | |
".dats", | |
".atxt", | |
".hats", | |
".sats" | |
], | |
"tm_scope": "source.ocaml" | |
}, | |
"Ada": { | |
"type": "programming", | |
"color": "#02f88c", | |
"extensions": [ | |
".adb", | |
".ads" | |
] | |
}, | |
"C#": { | |
"type": "programming", | |
"ace_mode": "csharp", | |
"tm_scope": "source.cs", | |
"search_term": "csharp", | |
"color": "#178600", | |
"aliases": [ | |
"csharp" | |
], | |
"extensions": [ | |
".cs", | |
".cshtml", | |
".csx" | |
] | |
}, | |
"Common Lisp": { | |
"type": "programming", | |
"tm_scope": "source.lisp", | |
"color": "#3fb68b", | |
"aliases": [ | |
"lisp" | |
], | |
"extensions": [ | |
".lisp", | |
".asd", | |
".cl", | |
".lsp", | |
".ny", | |
".podsl" | |
], | |
"interpreters": [ | |
"lisp", | |
"sbcl", | |
"ccl", | |
"clisp", | |
"ecl" | |
] | |
}, | |
"Component Pascal": { | |
"type": "programming", | |
"lexer": "Delphi", | |
"color": "#b0ce4e", | |
"extensions": [ | |
".cp", | |
".cps" | |
], | |
"tm_scope": "source.pascal" | |
}, | |
"Dylan": { | |
"type": "programming", | |
"color": "#3ebc27", | |
"extensions": [ | |
".dylan", | |
".intr", | |
".lid" | |
] | |
}, | |
"E": { | |
"type": "programming", | |
"color": "#ccce35", | |
"lexer": "Text only", | |
"extensions": [ | |
".E" | |
] | |
}, | |
"Erlang": { | |
"type": "programming", | |
"color": "#0faf8d", | |
"extensions": [ | |
".erl", | |
".escript", | |
".hrl" | |
] | |
}, | |
"Game Maker Language": { | |
"type": "programming", | |
"color": "#8ad353", | |
"lexer": "JavaScript", | |
"extensions": [ | |
".gml" | |
], | |
"tm_scope": "source.js" | |
}, | |
"Latte": { | |
"type": "markup", | |
"color": "#A8FF97", | |
"group": "HTML", | |
"lexer": "Smarty", | |
"extensions": [ | |
".latte" | |
], | |
"tm_scope": "source.smarty" | |
}, | |
"Nimrod": { | |
"type": "programming", | |
"color": "#37775b", | |
"extensions": [ | |
".nim", | |
".nimrod" | |
] | |
}, | |
"Nit": { | |
"type": "programming", | |
"lexer": "Text only", | |
"color": "#0d8921", | |
"extensions": [ | |
".nit" | |
] | |
}, | |
"Nix": { | |
"type": "programming", | |
"lexer": "Nix", | |
"extensions": [ | |
".nix" | |
] | |
}, | |
"Nu": { | |
"type": "programming", | |
"lexer": "Scheme", | |
"color": "#c9df40", | |
"aliases": [ | |
"nush" | |
], | |
"extensions": [ | |
".nu" | |
], | |
"filenames": [ | |
"Nukefile" | |
], | |
"tm_scope": "source.scheme" | |
}, | |
"NumPy": { | |
"group": "Python", | |
"extensions": [ | |
".numpy", | |
".numpyw", | |
".numsc" | |
] | |
}, | |
"OCaml": { | |
"type": "programming", | |
"ace_mode": "ocaml", | |
"color": "#3be133", | |
"extensions": [ | |
".ml", | |
".eliom", | |
".eliomi", | |
".ml4", | |
".mli", | |
".mll", | |
".mly" | |
] | |
}, | |
"Pure Data": { | |
"type": "programming", | |
"color": "#91de79", | |
"lexer": "Text only", | |
"extensions": [ | |
".pd" | |
] | |
}, | |
"PureScript": { | |
"type": "programming", | |
"color": "#bcdc53", | |
"lexer": "Haskell", | |
"extensions": [ | |
".purs" | |
], | |
"tm_scope": "source.haskell" | |
} | |
} | |
Object.keys(langs).map(function(l){ | |
var hex = langs[l].color | |
if (!hex) return | |
var div = document.createElement('div') | |
div.setAttribute('style', "width: 120px; height: 120px; float: left; background-color: " + hex + ';') | |
div.innerText = l | |
document.body.appendChild(div) | |
}) | |
require('insert-css')('html, body { font-family: "Courier New", "Helvetica"; overflow: auto; text-align: center; font-size: 12px; }') |
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
require=function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s}({"insert-css":[function(require,module,exports){var inserted={};module.exports=function(css,options){if(inserted[css])return;inserted[css]=true;var elem=document.createElement("style");elem.setAttribute("type","text/css");if("textContent"in elem){elem.textContent=css}else{elem.styleSheet.cssText=css}var head=document.getElementsByTagName("head")[0];if(options&&options.prepend){head.insertBefore(elem,head.childNodes[0])}else{head.appendChild(elem)}}},{}]},{},[]);var langs={ATS:{type:"programming",color:"#1ac620",lexer:"OCaml",aliases:["ats2"],extensions:[".dats",".atxt",".hats",".sats"],tm_scope:"source.ocaml"},Ada:{type:"programming",color:"#02f88c",extensions:[".adb",".ads"]},"C#":{type:"programming",ace_mode:"csharp",tm_scope:"source.cs",search_term:"csharp",color:"#178600",aliases:["csharp"],extensions:[".cs",".cshtml",".csx"]},"Common Lisp":{type:"programming",tm_scope:"source.lisp",color:"#3fb68b",aliases:["lisp"],extensions:[".lisp",".asd",".cl",".lsp",".ny",".podsl"],interpreters:["lisp","sbcl","ccl","clisp","ecl"]},"Component Pascal":{type:"programming",lexer:"Delphi",color:"#b0ce4e",extensions:[".cp",".cps"],tm_scope:"source.pascal"},Dylan:{type:"programming",color:"#3ebc27",extensions:[".dylan",".intr",".lid"]},E:{type:"programming",color:"#ccce35",lexer:"Text only",extensions:[".E"]},Erlang:{type:"programming",color:"#0faf8d",extensions:[".erl",".escript",".hrl"]},"Game Maker Language":{type:"programming",color:"#8ad353",lexer:"JavaScript",extensions:[".gml"],tm_scope:"source.js"},Latte:{type:"markup",color:"#A8FF97",group:"HTML",lexer:"Smarty",extensions:[".latte"],tm_scope:"source.smarty"},Nimrod:{type:"programming",color:"#37775b",extensions:[".nim",".nimrod"]},Nit:{type:"programming",lexer:"Text only",color:"#0d8921",extensions:[".nit"]},Nix:{type:"programming",lexer:"Nix",extensions:[".nix"]},Nu:{type:"programming",lexer:"Scheme",color:"#c9df40",aliases:["nush"],extensions:[".nu"],filenames:["Nukefile"],tm_scope:"source.scheme"},NumPy:{group:"Python",extensions:[".numpy",".numpyw",".numsc"]},OCaml:{type:"programming",ace_mode:"ocaml",color:"#3be133",extensions:[".ml",".eliom",".eliomi",".ml4",".mli",".mll",".mly"]},"Pure Data":{type:"programming",color:"#91de79",lexer:"Text only",extensions:[".pd"]},PureScript:{type:"programming",color:"#bcdc53",lexer:"Haskell",extensions:[".purs"],tm_scope:"source.haskell"}};Object.keys(langs).map(function(l){var hex=langs[l].color;if(!hex)return;var div=document.createElement("div");div.setAttribute("style","width: 120px; height: 120px; float: left; background-color: "+hex+";");div.innerText=l;document.body.appendChild(div)});require("insert-css")('html, body { font-family: "Courier New", "Helvetica"; overflow: auto; text-align: center; font-size: 12px; }'); |
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
{ | |
"name": "requirebin-sketch", | |
"version": "1.0.0", | |
"dependencies": { | |
"insert-css": "0.2.0" | |
} | |
} |
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
<style type='text/css'>html, body { margin: 0; padding: 0; border: 0; } | |
body, html { height: 100%; width: 100%; }</style> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment