commit 110a1b4797ab038cbf8c3eb5ca27af8d627e0d67 Author: Sven Slootweg Date: Tue Jan 23 02:54:50 2018 +0100 Initial commit diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..3c3629e --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +node_modules diff --git a/gulpfile.js b/gulpfile.js new file mode 100644 index 0000000..4c62574 --- /dev/null +++ b/gulpfile.js @@ -0,0 +1,79 @@ +const Promise = require("bluebird"); +const path = require("path"); +const gulp = require("gulp"); +const webpackStream = require("webpack-stream-fixed"); +const webpack = require("webpack"); +const gulpNamedLog = require("gulp-named-log"); +const gulpRename = require("gulp-rename"); +const gulpNodemon = require("gulp-nodemon"); +const gulpCached = require("gulp-cached"); +const presetSCSS = require("@joepie91/gulp-preset-scss"); + +const awaitServer = require("await-server"); + +const gulpLivereload = require("gulp-livereload"); +const patchLivereloadLogger = require("@joepie91/gulp-partial-patch-livereload-logger"); + +patchLivereloadLogger(gulpLivereload); + +let config = { + scss: { + source: "./src/scss/**/*.scss", + destination: "./public/css/" + } +} +// FIXME: Copy simple-line-icons + +let serverLogger = gulpNamedLog("server"); + +gulp.task("nodemon", ["scss", "livereload"], () => { + gulpNodemon({ + script: "server.js", + ignore: [ + "gulpfile.js", + "node_modules", + "public", + "src/frontend" + ], + ext: "js pug" + }).on("start", () => { + Promise.try(() => { + serverLogger.info("Starting..."); + return awaitServer(3000); + }).then(() => { + serverLogger.info("Started!"); + gulpLivereload.changed("*"); + }); + }); +}); + +gulp.task("scss", () => { + return gulp.src("./src/scss/style.scss") + .pipe(presetSCSS({ + livereload: gulpLivereload, + cacheKey: false + })) + .pipe(gulp.dest(config.scss.destination)); +}); + +gulp.task("livereload", () => { + gulpLivereload.listen({ + quiet: true + }); +}); + +gulp.task("webpack-watch", ["livereload"], () => { + return gulp.src("./src/frontend/index.js") + .pipe(webpackStream(require("./webpack.config.js"))) + .pipe(gulpNamedLog("webpack").stream()) + .pipe(gulpLivereload()) + .pipe(gulp.dest("./public/js/")); +}); + +gulp.task("watch-css", () => { + gulp.watch(config.scss.source, ["scss"]); +}); + +gulp.task("watch", ["webpack-watch", "nodemon", "watch-css"]); + +gulp.task("default", ["watch"]); diff --git a/package.json b/package.json new file mode 100644 index 0000000..f1c99f6 --- /dev/null +++ b/package.json @@ -0,0 +1,52 @@ +{ + "name": "play", + "version": "1.0.0", + "description": "", + "main": "index.js", + "scripts": { + "test": "echo \"Error: no test specified\" && exit 1" + }, + "repository": { + "type": "git", + "url": "http://git.cryto.net/joepie91/play.git" + }, + "keywords": [], + "author": "", + "license": "ISC", + "dependencies": { + "bluebird": "^3.5.1", + "create-event-emitter": "^1.0.0", + "express": "^4.16.2", + "express-promise-router": "^3.0.1", + "knex": "^0.14.2", + "pg": "^7.4.1", + "pug": "^2.0.0-rc.4" + }, + "devDependencies": { + "@joepie91/gulp-partial-patch-livereload-logger": "^1.0.1", + "@joepie91/gulp-preset-scss": "^1.1.0", + "await-server": "^1.0.0", + "babel-core": "^6.26.0", + "babel-loader": "7.1.1", + "babel-preset-es2015": "^6.24.1", + "babel-preset-react": "^6.24.1", + "browserify": "^14.5.0", + "classnames": "^2.2.5", + "create-react-class": "^15.6.2", + "document-ready-promise": "^3.0.1", + "glslify": "^6.1.0", + "glslify-loader": "^1.0.2", + "gulp": "^3.9.1", + "gulp-cached": "^1.1.1", + "gulp-livereload": "^3.8.1", + "gulp-named-log": "^1.0.1", + "gulp-nodemon": "^2.2.1", + "gulp-rename": "^1.2.2", + "raw-loader": "^0.5.1", + "react": "^16.2.0", + "react-dom": "^16.2.0", + "simple-line-icons": "^2.4.1", + "webpack": "^3.8.1", + "webpack-stream-fixed": "^3.2.2" + } +} diff --git a/public/css/simple-line-icons.css b/public/css/simple-line-icons.css new file mode 100644 index 0000000..a5e97e2 --- /dev/null +++ b/public/css/simple-line-icons.css @@ -0,0 +1,778 @@ +@font-face { + font-family: 'simple-line-icons'; + src: url('../fonts/Simple-Line-Icons.eot?v=2.4.0'); + src: url('../fonts/Simple-Line-Icons.eot?v=2.4.0#iefix') format('embedded-opentype'), url('../fonts/Simple-Line-Icons.woff2?v=2.4.0') format('woff2'), url('../fonts/Simple-Line-Icons.ttf?v=2.4.0') format('truetype'), url('../fonts/Simple-Line-Icons.woff?v=2.4.0') format('woff'), url('../fonts/Simple-Line-Icons.svg?v=2.4.0#simple-line-icons') format('svg'); + font-weight: normal; + font-style: normal; +} +/* + Use the following CSS code if you want to have a class per icon. + Instead of a list of all class selectors, you can use the generic [class*="icon-"] selector, but it's slower: +*/ +.icon-user, +.icon-people, +.icon-user-female, +.icon-user-follow, +.icon-user-following, +.icon-user-unfollow, +.icon-login, +.icon-logout, +.icon-emotsmile, +.icon-phone, +.icon-call-end, +.icon-call-in, +.icon-call-out, +.icon-map, +.icon-location-pin, +.icon-direction, +.icon-directions, +.icon-compass, +.icon-layers, +.icon-menu, +.icon-list, +.icon-options-vertical, +.icon-options, +.icon-arrow-down, +.icon-arrow-left, +.icon-arrow-right, +.icon-arrow-up, +.icon-arrow-up-circle, +.icon-arrow-left-circle, +.icon-arrow-right-circle, +.icon-arrow-down-circle, +.icon-check, +.icon-clock, +.icon-plus, +.icon-minus, +.icon-close, +.icon-event, +.icon-exclamation, +.icon-organization, +.icon-trophy, +.icon-screen-smartphone, +.icon-screen-desktop, +.icon-plane, +.icon-notebook, +.icon-mustache, +.icon-mouse, +.icon-magnet, +.icon-energy, +.icon-disc, +.icon-cursor, +.icon-cursor-move, +.icon-crop, +.icon-chemistry, +.icon-speedometer, +.icon-shield, +.icon-screen-tablet, +.icon-magic-wand, +.icon-hourglass, +.icon-graduation, +.icon-ghost, +.icon-game-controller, +.icon-fire, +.icon-eyeglass, +.icon-envelope-open, +.icon-envelope-letter, +.icon-bell, +.icon-badge, +.icon-anchor, +.icon-wallet, +.icon-vector, +.icon-speech, +.icon-puzzle, +.icon-printer, +.icon-present, +.icon-playlist, +.icon-pin, +.icon-picture, +.icon-handbag, +.icon-globe-alt, +.icon-globe, +.icon-folder-alt, +.icon-folder, +.icon-film, +.icon-feed, +.icon-drop, +.icon-drawer, +.icon-docs, +.icon-doc, +.icon-diamond, +.icon-cup, +.icon-calculator, +.icon-bubbles, +.icon-briefcase, +.icon-book-open, +.icon-basket-loaded, +.icon-basket, +.icon-bag, +.icon-action-undo, +.icon-action-redo, +.icon-wrench, +.icon-umbrella, +.icon-trash, +.icon-tag, +.icon-support, +.icon-frame, +.icon-size-fullscreen, +.icon-size-actual, +.icon-shuffle, +.icon-share-alt, +.icon-share, +.icon-rocket, +.icon-question, +.icon-pie-chart, +.icon-pencil, +.icon-note, +.icon-loop, +.icon-home, +.icon-grid, +.icon-graph, +.icon-microphone, +.icon-music-tone-alt, +.icon-music-tone, +.icon-earphones-alt, +.icon-earphones, +.icon-equalizer, +.icon-like, +.icon-dislike, +.icon-control-start, +.icon-control-rewind, +.icon-control-play, +.icon-control-pause, +.icon-control-forward, +.icon-control-end, +.icon-volume-1, +.icon-volume-2, +.icon-volume-off, +.icon-calendar, +.icon-bulb, +.icon-chart, +.icon-ban, +.icon-bubble, +.icon-camrecorder, +.icon-camera, +.icon-cloud-download, +.icon-cloud-upload, +.icon-envelope, +.icon-eye, +.icon-flag, +.icon-heart, +.icon-info, +.icon-key, +.icon-link, +.icon-lock, +.icon-lock-open, +.icon-magnifier, +.icon-magnifier-add, +.icon-magnifier-remove, +.icon-paper-clip, +.icon-paper-plane, +.icon-power, +.icon-refresh, +.icon-reload, +.icon-settings, +.icon-star, +.icon-symbol-female, +.icon-symbol-male, +.icon-target, +.icon-credit-card, +.icon-paypal, +.icon-social-tumblr, +.icon-social-twitter, +.icon-social-facebook, +.icon-social-instagram, +.icon-social-linkedin, +.icon-social-pinterest, +.icon-social-github, +.icon-social-google, +.icon-social-reddit, +.icon-social-skype, +.icon-social-dribbble, +.icon-social-behance, +.icon-social-foursqare, +.icon-social-soundcloud, +.icon-social-spotify, +.icon-social-stumbleupon, +.icon-social-youtube, +.icon-social-dropbox, +.icon-social-vkontakte, +.icon-social-steam { + font-family: 'simple-line-icons'; + speak: none; + font-style: normal; + font-weight: normal; + font-variant: normal; + text-transform: none; + line-height: 1; + /* Better Font Rendering =========== */ + -webkit-font-smoothing: antialiased; + -moz-osx-font-smoothing: grayscale; +} +.icon-user:before { + content: "\e005"; +} +.icon-people:before { + content: "\e001"; +} +.icon-user-female:before { + content: "\e000"; +} +.icon-user-follow:before { + content: "\e002"; +} +.icon-user-following:before { + content: "\e003"; +} +.icon-user-unfollow:before { + content: "\e004"; +} +.icon-login:before { + content: "\e066"; +} +.icon-logout:before { + content: "\e065"; +} +.icon-emotsmile:before { + content: "\e021"; +} +.icon-phone:before { + content: "\e600"; +} +.icon-call-end:before { + content: "\e048"; +} +.icon-call-in:before { + content: "\e047"; +} +.icon-call-out:before { + content: "\e046"; +} +.icon-map:before { + content: "\e033"; +} +.icon-location-pin:before { + content: "\e096"; +} +.icon-direction:before { + content: "\e042"; +} +.icon-directions:before { + content: "\e041"; +} +.icon-compass:before { + content: "\e045"; +} +.icon-layers:before { + content: "\e034"; +} +.icon-menu:before { + content: "\e601"; +} +.icon-list:before { + content: "\e067"; +} +.icon-options-vertical:before { + content: "\e602"; +} +.icon-options:before { + content: "\e603"; +} +.icon-arrow-down:before { + content: "\e604"; +} +.icon-arrow-left:before { + content: "\e605"; +} +.icon-arrow-right:before { + content: "\e606"; +} +.icon-arrow-up:before { + content: "\e607"; +} +.icon-arrow-up-circle:before { + content: "\e078"; +} +.icon-arrow-left-circle:before { + content: "\e07a"; +} +.icon-arrow-right-circle:before { + content: "\e079"; +} +.icon-arrow-down-circle:before { + content: "\e07b"; +} +.icon-check:before { + content: "\e080"; +} +.icon-clock:before { + content: "\e081"; +} +.icon-plus:before { + content: "\e095"; +} +.icon-minus:before { + content: "\e615"; +} +.icon-close:before { + content: "\e082"; +} +.icon-event:before { + content: "\e619"; +} +.icon-exclamation:before { + content: "\e617"; +} +.icon-organization:before { + content: "\e616"; +} +.icon-trophy:before { + content: "\e006"; +} +.icon-screen-smartphone:before { + content: "\e010"; +} +.icon-screen-desktop:before { + content: "\e011"; +} +.icon-plane:before { + content: "\e012"; +} +.icon-notebook:before { + content: "\e013"; +} +.icon-mustache:before { + content: "\e014"; +} +.icon-mouse:before { + content: "\e015"; +} +.icon-magnet:before { + content: "\e016"; +} +.icon-energy:before { + content: "\e020"; +} +.icon-disc:before { + content: "\e022"; +} +.icon-cursor:before { + content: "\e06e"; +} +.icon-cursor-move:before { + content: "\e023"; +} +.icon-crop:before { + content: "\e024"; +} +.icon-chemistry:before { + content: "\e026"; +} +.icon-speedometer:before { + content: "\e007"; +} +.icon-shield:before { + content: "\e00e"; +} +.icon-screen-tablet:before { + content: "\e00f"; +} +.icon-magic-wand:before { + content: "\e017"; +} +.icon-hourglass:before { + content: "\e018"; +} +.icon-graduation:before { + content: "\e019"; +} +.icon-ghost:before { + content: "\e01a"; +} +.icon-game-controller:before { + content: "\e01b"; +} +.icon-fire:before { + content: "\e01c"; +} +.icon-eyeglass:before { + content: "\e01d"; +} +.icon-envelope-open:before { + content: "\e01e"; +} +.icon-envelope-letter:before { + content: "\e01f"; +} +.icon-bell:before { + content: "\e027"; +} +.icon-badge:before { + content: "\e028"; +} +.icon-anchor:before { + content: "\e029"; +} +.icon-wallet:before { + content: "\e02a"; +} +.icon-vector:before { + content: "\e02b"; +} +.icon-speech:before { + content: "\e02c"; +} +.icon-puzzle:before { + content: "\e02d"; +} +.icon-printer:before { + content: "\e02e"; +} +.icon-present:before { + content: "\e02f"; +} +.icon-playlist:before { + content: "\e030"; +} +.icon-pin:before { + content: "\e031"; +} +.icon-picture:before { + content: "\e032"; +} +.icon-handbag:before { + content: "\e035"; +} +.icon-globe-alt:before { + content: "\e036"; +} +.icon-globe:before { + content: "\e037"; +} +.icon-folder-alt:before { + content: "\e039"; +} +.icon-folder:before { + content: "\e089"; +} +.icon-film:before { + content: "\e03a"; +} +.icon-feed:before { + content: "\e03b"; +} +.icon-drop:before { + content: "\e03e"; +} +.icon-drawer:before { + content: "\e03f"; +} +.icon-docs:before { + content: "\e040"; +} +.icon-doc:before { + content: "\e085"; +} +.icon-diamond:before { + content: "\e043"; +} +.icon-cup:before { + content: "\e044"; +} +.icon-calculator:before { + content: "\e049"; +} +.icon-bubbles:before { + content: "\e04a"; +} +.icon-briefcase:before { + content: "\e04b"; +} +.icon-book-open:before { + content: "\e04c"; +} +.icon-basket-loaded:before { + content: "\e04d"; +} +.icon-basket:before { + content: "\e04e"; +} +.icon-bag:before { + content: "\e04f"; +} +.icon-action-undo:before { + content: "\e050"; +} +.icon-action-redo:before { + content: "\e051"; +} +.icon-wrench:before { + content: "\e052"; +} +.icon-umbrella:before { + content: "\e053"; +} +.icon-trash:before { + content: "\e054"; +} +.icon-tag:before { + content: "\e055"; +} +.icon-support:before { + content: "\e056"; +} +.icon-frame:before { + content: "\e038"; +} +.icon-size-fullscreen:before { + content: "\e057"; +} +.icon-size-actual:before { + content: "\e058"; +} +.icon-shuffle:before { + content: "\e059"; +} +.icon-share-alt:before { + content: "\e05a"; +} +.icon-share:before { + content: "\e05b"; +} +.icon-rocket:before { + content: "\e05c"; +} +.icon-question:before { + content: "\e05d"; +} +.icon-pie-chart:before { + content: "\e05e"; +} +.icon-pencil:before { + content: "\e05f"; +} +.icon-note:before { + content: "\e060"; +} +.icon-loop:before { + content: "\e064"; +} +.icon-home:before { + content: "\e069"; +} +.icon-grid:before { + content: "\e06a"; +} +.icon-graph:before { + content: "\e06b"; +} +.icon-microphone:before { + content: "\e063"; +} +.icon-music-tone-alt:before { + content: "\e061"; +} +.icon-music-tone:before { + content: "\e062"; +} +.icon-earphones-alt:before { + content: "\e03c"; +} +.icon-earphones:before { + content: "\e03d"; +} +.icon-equalizer:before { + content: "\e06c"; +} +.icon-like:before { + content: "\e068"; +} +.icon-dislike:before { + content: "\e06d"; +} +.icon-control-start:before { + content: "\e06f"; +} +.icon-control-rewind:before { + content: "\e070"; +} +.icon-control-play:before { + content: "\e071"; +} +.icon-control-pause:before { + content: "\e072"; +} +.icon-control-forward:before { + content: "\e073"; +} +.icon-control-end:before { + content: "\e074"; +} +.icon-volume-1:before { + content: "\e09f"; +} +.icon-volume-2:before { + content: "\e0a0"; +} +.icon-volume-off:before { + content: "\e0a1"; +} +.icon-calendar:before { + content: "\e075"; +} +.icon-bulb:before { + content: "\e076"; +} +.icon-chart:before { + content: "\e077"; +} +.icon-ban:before { + content: "\e07c"; +} +.icon-bubble:before { + content: "\e07d"; +} +.icon-camrecorder:before { + content: "\e07e"; +} +.icon-camera:before { + content: "\e07f"; +} +.icon-cloud-download:before { + content: "\e083"; +} +.icon-cloud-upload:before { + content: "\e084"; +} +.icon-envelope:before { + content: "\e086"; +} +.icon-eye:before { + content: "\e087"; +} +.icon-flag:before { + content: "\e088"; +} +.icon-heart:before { + content: "\e08a"; +} +.icon-info:before { + content: "\e08b"; +} +.icon-key:before { + content: "\e08c"; +} +.icon-link:before { + content: "\e08d"; +} +.icon-lock:before { + content: "\e08e"; +} +.icon-lock-open:before { + content: "\e08f"; +} +.icon-magnifier:before { + content: "\e090"; +} +.icon-magnifier-add:before { + content: "\e091"; +} +.icon-magnifier-remove:before { + content: "\e092"; +} +.icon-paper-clip:before { + content: "\e093"; +} +.icon-paper-plane:before { + content: "\e094"; +} +.icon-power:before { + content: "\e097"; +} +.icon-refresh:before { + content: "\e098"; +} +.icon-reload:before { + content: "\e099"; +} +.icon-settings:before { + content: "\e09a"; +} +.icon-star:before { + content: "\e09b"; +} +.icon-symbol-female:before { + content: "\e09c"; +} +.icon-symbol-male:before { + content: "\e09d"; +} +.icon-target:before { + content: "\e09e"; +} +.icon-credit-card:before { + content: "\e025"; +} +.icon-paypal:before { + content: "\e608"; +} +.icon-social-tumblr:before { + content: "\e00a"; +} +.icon-social-twitter:before { + content: "\e009"; +} +.icon-social-facebook:before { + content: "\e00b"; +} +.icon-social-instagram:before { + content: "\e609"; +} +.icon-social-linkedin:before { + content: "\e60a"; +} +.icon-social-pinterest:before { + content: "\e60b"; +} +.icon-social-github:before { + content: "\e60c"; +} +.icon-social-google:before { + content: "\e60d"; +} +.icon-social-reddit:before { + content: "\e60e"; +} +.icon-social-skype:before { + content: "\e60f"; +} +.icon-social-dribbble:before { + content: "\e00d"; +} +.icon-social-behance:before { + content: "\e610"; +} +.icon-social-foursqare:before { + content: "\e611"; +} +.icon-social-soundcloud:before { + content: "\e612"; +} +.icon-social-spotify:before { + content: "\e613"; +} +.icon-social-stumbleupon:before { + content: "\e614"; +} +.icon-social-youtube:before { + content: "\e008"; +} +.icon-social-dropbox:before { + content: "\e00c"; +} +.icon-social-vkontakte:before { + content: "\e618"; +} +.icon-social-steam:before { + content: "\e620"; +} diff --git a/public/css/style.css b/public/css/style.css new file mode 100644 index 0000000..fb33821 --- /dev/null +++ b/public/css/style.css @@ -0,0 +1,214 @@ +/* Source: https://github.com/mobify/spline/blob/master/dist/functions/reverse-gradient/_reverse-gradient.scss */ +.editor-input-horizontal .editor-input { + margin-right: 6px; + display: inline-block; } + +.editor-input-horizontal .editor-input:last-child { + margin-right: 0px; } + +.editor-input-vertical .editor-input { + margin-bottom: 4px; } + +.editor-input-vertical .editor-input:last-child { + margin-bottom: 0px; } + +.editor-input-label { + font-size: 12px; } + +.editor-input-label-inline { + display: inline-block; + margin-right: 6px; } + +.editor-input-text { + padding: 2px 6px; + border-radius: 7px; + color: black; + font-size: 12px; + border: 1px solid #454545; + box-shadow: inset 1px 1px rgba(94, 94, 94, 0.74), inset -1px -1px rgba(189, 189, 189, 0.27); + font-family: "Noto Sans", sans-serif; + background: linear-gradient(to bottom, #A5A5A5 0%, #B5B5B5 100%); } + +.editor-input-button { + padding: 2px 6px; + border-radius: 7px; + color: black; + font-size: 12px; + border: 1px solid #454545; + box-shadow: inset -1px -1px rgba(94, 94, 94, 0.74), inset 1px 1px rgba(189, 189, 189, 0.27); + user-select: none; + -moz-user-select: none; + -webkit-user-select: none; + -ms-user-select: none; + background: linear-gradient(to bottom, #A6A6A6 0%, #8E8E8E 100%); + cursor: default; } + .editor-input-button:active { + box-shadow: inset 1px 1px rgba(94, 94, 94, 0.74), inset -1px -1px rgba(189, 189, 189, 0.27); + background: linear-gradient(to bottom, #A6A6A6 100%, #8E8E8E 0%); } + +.editor-input-buttonset-horizontal .editor-input-button { + display: inline-block; + margin-right: 0px; } + .editor-input-buttonset-horizontal .editor-input-button:first-child { + border-top-right-radius: 0px; + border-bottom-right-radius: 0px; } + .editor-input-buttonset-horizontal .editor-input-button:last-child { + border-top-left-radius: 0px; + border-bottom-left-radius: 0px; + border-left-width: 0px; } + .editor-input-buttonset-horizontal .editor-input-button:not(:first-child):not(:last-child) { + border-radius: 0px; + border-left-width: 0px; } + +.editor-input-buttonset-vertical .editor-input-button { + width: 180px; } + .editor-input-buttonset-vertical .editor-input-button:first-child { + border-bottom-left-radius: 0px; + border-bottom-right-radius: 0px; } + .editor-input-buttonset-vertical .editor-input-button:last-child { + border-top-left-radius: 0px; + border-top-right-radius: 0px; + border-top-width: 0px; } + .editor-input-buttonset-vertical .editor-input-button:not(:first-child):not(:last-child) { + border-radius: 0px; + border-top-width: 0px; } + +.editor-panel-header, .editor-control-bar { + box-shadow: inset -1px -1px rgba(94, 94, 94, 0.74), inset 1px 1px rgba(189, 189, 189, 0.27); + user-select: none; + -moz-user-select: none; + -webkit-user-select: none; + -ms-user-select: none; + background: #686868; + cursor: default; } + +.editor-panel-header { + font-weight: bold; + padding: 3px 5px; } + +.editor-control-bar { + box-shadow: inset -1px -1px rgba(94, 94, 94, 0.74), inset 1px 1px rgba(189, 189, 189, 0.27), 0px 1px 1px 0px rgba(54, 54, 54, 0.79); + z-index: 999; + padding: 4px 6px; } + +/* + font-family: 'Open Sans', sans-serif; + font-family: 'Catamaran', sans-serif; + font-family: 'Noto Sans', sans-serif; + font-family: 'Source Sans Pro', sans-serif; +*/ +body { + font-family: 'Noto Sans', sans-serif; + margin: 0px; + padding: 0px; + color: black; } + +h1 { + margin: 0px; } + +.editor-app { + display: grid; + grid-template-columns: 300px 1fr; + grid-template-rows: auto 1fr; + width: 100vw; + height: 100vh; } + .editor-app > .header { + grid-column-start: 1; + grid-column-end: 3; + padding: 6px 8px; + background: linear-gradient(to bottom, #232323 0%, #161616 100%); + color: #aad400ff; } + .editor-app > .header .logo { + margin-right: 8px; } + .editor-app > .header .name { + position: relative; + top: -2px; } + .editor-app .menu { + display: grid; + grid-template-rows: auto 1fr; + box-sizing: border-box; + background-color: #010801; + border-right: 1px solid #454545; + background: #737373; } + .editor-app .menu .item-browser { + box-shadow: inset 1px 1px rgba(94, 94, 94, 0.74), inset -1px -1px rgba(189, 189, 189, 0.27); + overflow-y: auto; } + .editor-app .menu .item-browser .item:nth-child(even) { + font-size: 14px; + padding: 4px 6px; + background-color: #797979; } + .editor-app .menu .item-browser .item:nth-child(odd) { + font-size: 14px; + padding: 4px 6px; + background-color: #737373; } + .editor-app .menu .item-browser .item .icon { + position: relative; + top: 1px; + margin-right: 6px; } + .editor-app .canvas { + box-sizing: border-box; + padding: 16px; + background-color: #373737; + box-shadow: inset 1px 1px rgba(0, 0, 0, 0.62); } + .editor-app .canvas .node { + font-size: 13px; + display: grid; + grid-template-columns: auto 8px auto 8px auto; + grid-template-rows: auto auto 8px; + position: absolute; + top: 80px; + left: 400px; } + .editor-app .canvas .node .editor-panel-header, .editor-app .canvas .node .background { + grid-column-start: 2; + grid-column-end: 5; } + .editor-app .canvas .node .editor-panel-header { + cursor: move; + grid-row-start: 1; + grid-row-end: 2; } + .editor-app .canvas .node .background { + grid-row-start: 2; + grid-row-end: 4; + background-color: #737373; + box-shadow: inset -1px -1px rgba(94, 94, 94, 0.74), inset 1px 1px rgba(189, 189, 189, 0.27), 2px 2px 2px 0px rgba(28, 28, 28, 0.79); } + .editor-app .canvas .node .inputs, .editor-app .canvas .node .left-connectors, .editor-app .canvas .node .right-connectors { + grid-row-start: 2; + grid-row-end: 3; + z-index: 2; } + .editor-app .canvas .node .inputs { + grid-column-start: 3; + grid-column-end: 4; + padding: 8px 16px; } + .editor-app .canvas .node .inputs .label, .editor-app .canvas .node .inputs .box { + display: inline-block; } + .editor-app .canvas .node .inputs .label { + margin-right: 8px; } + .editor-app .canvas .node .left-connectors, .editor-app .canvas .node .right-connectors { + z-index: 2; } + .editor-app .canvas .node .left-connectors .connector, .editor-app .canvas .node .right-connectors .connector { + margin: 6px 0px; } + .editor-app .canvas .node .left-connectors .connector .bullet, .editor-app .canvas .node .left-connectors .connector .description, .editor-app .canvas .node .right-connectors .connector .bullet, .editor-app .canvas .node .right-connectors .connector .description { + display: inline-block; } + .editor-app .canvas .node .left-connectors .connector .bullet, .editor-app .canvas .node .right-connectors .connector .bullet { + width: 16px; + height: 16px; + background-color: #8d8d8d; + border: 1px solid #454545; + border-radius: 8px; + position: relative; + top: 5px; } + .editor-app .canvas .node .left-connectors .connector .description, .editor-app .canvas .node .right-connectors .connector .description { + font-size: 12px; + background-color: rgba(180, 180, 180, 0.6); + padding: 2px 4px; + border-radius: 4px; } + .editor-app .canvas .node .left-connectors { + grid-column-start: 1; + grid-column-end: 3; + text-align: right; } + .editor-app .canvas .node .left-connectors .bullet { + margin-left: 6px; } + .editor-app .canvas .node .right-connectors { + grid-column-start: 4; + grid-column-end: 6; } + .editor-app .canvas .node .right-connectors .bullet { + margin-right: 6px; } diff --git a/public/fonts/Simple-Line-Icons.eot b/public/fonts/Simple-Line-Icons.eot new file mode 100644 index 0000000..f0ca6e8 Binary files /dev/null and b/public/fonts/Simple-Line-Icons.eot differ diff --git a/public/fonts/Simple-Line-Icons.svg b/public/fonts/Simple-Line-Icons.svg new file mode 100644 index 0000000..4988524 --- /dev/null +++ b/public/fonts/Simple-Line-Icons.svg @@ -0,0 +1,200 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/public/fonts/Simple-Line-Icons.ttf b/public/fonts/Simple-Line-Icons.ttf new file mode 100644 index 0000000..6ecb686 Binary files /dev/null and b/public/fonts/Simple-Line-Icons.ttf differ diff --git a/public/fonts/Simple-Line-Icons.woff b/public/fonts/Simple-Line-Icons.woff new file mode 100644 index 0000000..b17d694 Binary files /dev/null and b/public/fonts/Simple-Line-Icons.woff differ diff --git a/public/fonts/Simple-Line-Icons.woff2 b/public/fonts/Simple-Line-Icons.woff2 new file mode 100644 index 0000000..c49fccf Binary files /dev/null and b/public/fonts/Simple-Line-Icons.woff2 differ diff --git a/public/images/icons/folder-16.png b/public/images/icons/folder-16.png new file mode 100644 index 0000000..e9dc51f Binary files /dev/null and b/public/images/icons/folder-16.png differ diff --git a/public/images/icons/folder-32.png b/public/images/icons/folder-32.png new file mode 100644 index 0000000..f26c2a1 Binary files /dev/null and b/public/images/icons/folder-32.png differ diff --git a/public/images/icons/folder-64.png b/public/images/icons/folder-64.png new file mode 100644 index 0000000..468a2a0 Binary files /dev/null and b/public/images/icons/folder-64.png differ diff --git a/public/images/icons/object-16.png b/public/images/icons/object-16.png new file mode 100644 index 0000000..3253c72 Binary files /dev/null and b/public/images/icons/object-16.png differ diff --git a/public/images/icons/object-32.png b/public/images/icons/object-32.png new file mode 100644 index 0000000..6120e8c Binary files /dev/null and b/public/images/icons/object-32.png differ diff --git a/public/images/icons/object-64.png b/public/images/icons/object-64.png new file mode 100644 index 0000000..4203127 Binary files /dev/null and b/public/images/icons/object-64.png differ diff --git a/public/images/logo-128.png b/public/images/logo-128.png new file mode 100644 index 0000000..26e898a Binary files /dev/null and b/public/images/logo-128.png differ diff --git a/public/images/logo-16.png b/public/images/logo-16.png new file mode 100644 index 0000000..96e1cc3 Binary files /dev/null and b/public/images/logo-16.png differ diff --git a/public/images/logo-256.png b/public/images/logo-256.png new file mode 100644 index 0000000..95769cc Binary files /dev/null and b/public/images/logo-256.png differ diff --git a/public/images/logo-32.png b/public/images/logo-32.png new file mode 100644 index 0000000..b728c72 Binary files /dev/null and b/public/images/logo-32.png differ diff --git a/public/images/logo-64.png b/public/images/logo-64.png new file mode 100644 index 0000000..6ab1547 Binary files /dev/null and b/public/images/logo-64.png differ diff --git a/public/js/bundle.js b/public/js/bundle.js new file mode 100644 index 0000000..cf86e22 --- /dev/null +++ b/public/js/bundle.js @@ -0,0 +1,25858 @@ +/******/ (function(modules) { // webpackBootstrap +/******/ // The module cache +/******/ var installedModules = {}; +/******/ +/******/ // The require function +/******/ function __webpack_require__(moduleId) { +/******/ +/******/ // Check if module is in cache +/******/ if(installedModules[moduleId]) +/******/ return installedModules[moduleId].exports; +/******/ +/******/ // Create a new module (and put it into the cache) +/******/ var module = installedModules[moduleId] = { +/******/ exports: {}, +/******/ id: moduleId, +/******/ loaded: false +/******/ }; +/******/ +/******/ // Execute the module function +/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__); +/******/ +/******/ // Flag the module as loaded +/******/ module.loaded = true; +/******/ +/******/ // Return the exports of the module +/******/ return module.exports; +/******/ } +/******/ +/******/ +/******/ // expose the modules object (__webpack_modules__) +/******/ __webpack_require__.m = modules; +/******/ +/******/ // expose the module cache +/******/ __webpack_require__.c = installedModules; +/******/ +/******/ // __webpack_public_path__ +/******/ __webpack_require__.p = ""; +/******/ +/******/ // Load entry module and return exports +/******/ return __webpack_require__(0); +/******/ }) +/************************************************************************/ +/******/ ([ +/* 0 */ +/***/ (function(module, exports, __webpack_require__) { + + 'use strict'; + + // NOTE: This file will eventually contain non-editor JS. For now, it's just a 'redirect' to the editor implementation. + + __webpack_require__(1); + +/***/ }), +/* 1 */ +/***/ (function(module, exports, __webpack_require__) { + + 'use strict'; + + var Promise = __webpack_require__(2); + var React = __webpack_require__(41); + var ReactDOM = __webpack_require__(51); + var documentReadyPromise = __webpack_require__(67); + + var App = __webpack_require__(68); + + Promise.try(function () { + return documentReadyPromise(); + }).then(function () { + ReactDOM.render(React.createElement(App, null), document.getElementById("editor-app")); + }).catch(function (err) { + console.error(err); + }); + +/***/ }), +/* 2 */ +/***/ (function(module, exports, __webpack_require__) { + + "use strict"; + var old; + if (typeof Promise !== "undefined") old = Promise; + function noConflict() { + try { if (Promise === bluebird) Promise = old; } + catch (e) {} + return bluebird; + } + var bluebird = __webpack_require__(3)(); + bluebird.noConflict = noConflict; + module.exports = bluebird; + + +/***/ }), +/* 3 */ +/***/ (function(module, exports, __webpack_require__) { + + /* WEBPACK VAR INJECTION */(function(process) {"use strict"; + module.exports = function() { + var makeSelfResolutionError = function () { + return new TypeError("circular promise resolution chain\u000a\u000a See http://goo.gl/MqrFmX\u000a"); + }; + var reflectHandler = function() { + return new Promise.PromiseInspection(this._target()); + }; + var apiRejection = function(msg) { + return Promise.reject(new TypeError(msg)); + }; + function Proxyable() {} + var UNDEFINED_BINDING = {}; + var util = __webpack_require__(5); + + var getDomain; + if (util.isNode) { + getDomain = function() { + var ret = process.domain; + if (ret === undefined) ret = null; + return ret; + }; + } else { + getDomain = function() { + return null; + }; + } + util.notEnumerableProp(Promise, "_getDomain", getDomain); + + var es5 = __webpack_require__(6); + var Async = __webpack_require__(7); + var async = new Async(); + es5.defineProperty(Promise, "_async", {value: async}); + var errors = __webpack_require__(12); + var TypeError = Promise.TypeError = errors.TypeError; + Promise.RangeError = errors.RangeError; + var CancellationError = Promise.CancellationError = errors.CancellationError; + Promise.TimeoutError = errors.TimeoutError; + Promise.OperationalError = errors.OperationalError; + Promise.RejectionError = errors.OperationalError; + Promise.AggregateError = errors.AggregateError; + var INTERNAL = function(){}; + var APPLY = {}; + var NEXT_FILTER = {}; + var tryConvertToPromise = __webpack_require__(13)(Promise, INTERNAL); + var PromiseArray = + __webpack_require__(14)(Promise, INTERNAL, + tryConvertToPromise, apiRejection, Proxyable); + var Context = __webpack_require__(15)(Promise); + /*jshint unused:false*/ + var createContext = Context.create; + var debug = __webpack_require__(16)(Promise, Context); + var CapturedTrace = debug.CapturedTrace; + var PassThroughHandlerContext = + __webpack_require__(17)(Promise, tryConvertToPromise, NEXT_FILTER); + var catchFilter = __webpack_require__(18)(NEXT_FILTER); + var nodebackForPromise = __webpack_require__(19); + var errorObj = util.errorObj; + var tryCatch = util.tryCatch; + function check(self, executor) { + if (self == null || self.constructor !== Promise) { + throw new TypeError("the promise constructor cannot be invoked directly\u000a\u000a See http://goo.gl/MqrFmX\u000a"); + } + if (typeof executor !== "function") { + throw new TypeError("expecting a function but got " + util.classString(executor)); + } + + } + + function Promise(executor) { + if (executor !== INTERNAL) { + check(this, executor); + } + this._bitField = 0; + this._fulfillmentHandler0 = undefined; + this._rejectionHandler0 = undefined; + this._promise0 = undefined; + this._receiver0 = undefined; + this._resolveFromExecutor(executor); + this._promiseCreated(); + this._fireEvent("promiseCreated", this); + } + + Promise.prototype.toString = function () { + return "[object Promise]"; + }; + + Promise.prototype.caught = Promise.prototype["catch"] = function (fn) { + var len = arguments.length; + if (len > 1) { + var catchInstances = new Array(len - 1), + j = 0, i; + for (i = 0; i < len - 1; ++i) { + var item = arguments[i]; + if (util.isObject(item)) { + catchInstances[j++] = item; + } else { + return apiRejection("Catch statement predicate: " + + "expecting an object but got " + util.classString(item)); + } + } + catchInstances.length = j; + fn = arguments[i]; + return this.then(undefined, catchFilter(catchInstances, fn, this)); + } + return this.then(undefined, fn); + }; + + Promise.prototype.reflect = function () { + return this._then(reflectHandler, + reflectHandler, undefined, this, undefined); + }; + + Promise.prototype.then = function (didFulfill, didReject) { + if (debug.warnings() && arguments.length > 0 && + typeof didFulfill !== "function" && + typeof didReject !== "function") { + var msg = ".then() only accepts functions but was passed: " + + util.classString(didFulfill); + if (arguments.length > 1) { + msg += ", " + util.classString(didReject); + } + this._warn(msg); + } + return this._then(didFulfill, didReject, undefined, undefined, undefined); + }; + + Promise.prototype.done = function (didFulfill, didReject) { + var promise = + this._then(didFulfill, didReject, undefined, undefined, undefined); + promise._setIsFinal(); + }; + + Promise.prototype.spread = function (fn) { + if (typeof fn !== "function") { + return apiRejection("expecting a function but got " + util.classString(fn)); + } + return this.all()._then(fn, undefined, undefined, APPLY, undefined); + }; + + Promise.prototype.toJSON = function () { + var ret = { + isFulfilled: false, + isRejected: false, + fulfillmentValue: undefined, + rejectionReason: undefined + }; + if (this.isFulfilled()) { + ret.fulfillmentValue = this.value(); + ret.isFulfilled = true; + } else if (this.isRejected()) { + ret.rejectionReason = this.reason(); + ret.isRejected = true; + } + return ret; + }; + + Promise.prototype.all = function () { + if (arguments.length > 0) { + this._warn(".all() was passed arguments but it does not take any"); + } + return new PromiseArray(this).promise(); + }; + + Promise.prototype.error = function (fn) { + return this.caught(util.originatesFromRejection, fn); + }; + + Promise.getNewLibraryCopy = module.exports; + + Promise.is = function (val) { + return val instanceof Promise; + }; + + Promise.fromNode = Promise.fromCallback = function(fn) { + var ret = new Promise(INTERNAL); + ret._captureStackTrace(); + var multiArgs = arguments.length > 1 ? !!Object(arguments[1]).multiArgs + : false; + var result = tryCatch(fn)(nodebackForPromise(ret, multiArgs)); + if (result === errorObj) { + ret._rejectCallback(result.e, true); + } + if (!ret._isFateSealed()) ret._setAsyncGuaranteed(); + return ret; + }; + + Promise.all = function (promises) { + return new PromiseArray(promises).promise(); + }; + + Promise.cast = function (obj) { + var ret = tryConvertToPromise(obj); + if (!(ret instanceof Promise)) { + ret = new Promise(INTERNAL); + ret._captureStackTrace(); + ret._setFulfilled(); + ret._rejectionHandler0 = obj; + } + return ret; + }; + + Promise.resolve = Promise.fulfilled = Promise.cast; + + Promise.reject = Promise.rejected = function (reason) { + var ret = new Promise(INTERNAL); + ret._captureStackTrace(); + ret._rejectCallback(reason, true); + return ret; + }; + + Promise.setScheduler = function(fn) { + if (typeof fn !== "function") { + throw new TypeError("expecting a function but got " + util.classString(fn)); + } + return async.setScheduler(fn); + }; + + Promise.prototype._then = function ( + didFulfill, + didReject, + _, receiver, + internalData + ) { + var haveInternalData = internalData !== undefined; + var promise = haveInternalData ? internalData : new Promise(INTERNAL); + var target = this._target(); + var bitField = target._bitField; + + if (!haveInternalData) { + promise._propagateFrom(this, 3); + promise._captureStackTrace(); + if (receiver === undefined && + ((this._bitField & 2097152) !== 0)) { + if (!((bitField & 50397184) === 0)) { + receiver = this._boundValue(); + } else { + receiver = target === this ? undefined : this._boundTo; + } + } + this._fireEvent("promiseChained", this, promise); + } + + var domain = getDomain(); + if (!((bitField & 50397184) === 0)) { + var handler, value, settler = target._settlePromiseCtx; + if (((bitField & 33554432) !== 0)) { + value = target._rejectionHandler0; + handler = didFulfill; + } else if (((bitField & 16777216) !== 0)) { + value = target._fulfillmentHandler0; + handler = didReject; + target._unsetRejectionIsUnhandled(); + } else { + settler = target._settlePromiseLateCancellationObserver; + value = new CancellationError("late cancellation observer"); + target._attachExtraTrace(value); + handler = didReject; + } + + async.invoke(settler, target, { + handler: domain === null ? handler + : (typeof handler === "function" && + util.domainBind(domain, handler)), + promise: promise, + receiver: receiver, + value: value + }); + } else { + target._addCallbacks(didFulfill, didReject, promise, receiver, domain); + } + + return promise; + }; + + Promise.prototype._length = function () { + return this._bitField & 65535; + }; + + Promise.prototype._isFateSealed = function () { + return (this._bitField & 117506048) !== 0; + }; + + Promise.prototype._isFollowing = function () { + return (this._bitField & 67108864) === 67108864; + }; + + Promise.prototype._setLength = function (len) { + this._bitField = (this._bitField & -65536) | + (len & 65535); + }; + + Promise.prototype._setFulfilled = function () { + this._bitField = this._bitField | 33554432; + this._fireEvent("promiseFulfilled", this); + }; + + Promise.prototype._setRejected = function () { + this._bitField = this._bitField | 16777216; + this._fireEvent("promiseRejected", this); + }; + + Promise.prototype._setFollowing = function () { + this._bitField = this._bitField | 67108864; + this._fireEvent("promiseResolved", this); + }; + + Promise.prototype._setIsFinal = function () { + this._bitField = this._bitField | 4194304; + }; + + Promise.prototype._isFinal = function () { + return (this._bitField & 4194304) > 0; + }; + + Promise.prototype._unsetCancelled = function() { + this._bitField = this._bitField & (~65536); + }; + + Promise.prototype._setCancelled = function() { + this._bitField = this._bitField | 65536; + this._fireEvent("promiseCancelled", this); + }; + + Promise.prototype._setWillBeCancelled = function() { + this._bitField = this._bitField | 8388608; + }; + + Promise.prototype._setAsyncGuaranteed = function() { + if (async.hasCustomScheduler()) return; + this._bitField = this._bitField | 134217728; + }; + + Promise.prototype._receiverAt = function (index) { + var ret = index === 0 ? this._receiver0 : this[ + index * 4 - 4 + 3]; + if (ret === UNDEFINED_BINDING) { + return undefined; + } else if (ret === undefined && this._isBound()) { + return this._boundValue(); + } + return ret; + }; + + Promise.prototype._promiseAt = function (index) { + return this[ + index * 4 - 4 + 2]; + }; + + Promise.prototype._fulfillmentHandlerAt = function (index) { + return this[ + index * 4 - 4 + 0]; + }; + + Promise.prototype._rejectionHandlerAt = function (index) { + return this[ + index * 4 - 4 + 1]; + }; + + Promise.prototype._boundValue = function() {}; + + Promise.prototype._migrateCallback0 = function (follower) { + var bitField = follower._bitField; + var fulfill = follower._fulfillmentHandler0; + var reject = follower._rejectionHandler0; + var promise = follower._promise0; + var receiver = follower._receiverAt(0); + if (receiver === undefined) receiver = UNDEFINED_BINDING; + this._addCallbacks(fulfill, reject, promise, receiver, null); + }; + + Promise.prototype._migrateCallbackAt = function (follower, index) { + var fulfill = follower._fulfillmentHandlerAt(index); + var reject = follower._rejectionHandlerAt(index); + var promise = follower._promiseAt(index); + var receiver = follower._receiverAt(index); + if (receiver === undefined) receiver = UNDEFINED_BINDING; + this._addCallbacks(fulfill, reject, promise, receiver, null); + }; + + Promise.prototype._addCallbacks = function ( + fulfill, + reject, + promise, + receiver, + domain + ) { + var index = this._length(); + + if (index >= 65535 - 4) { + index = 0; + this._setLength(0); + } + + if (index === 0) { + this._promise0 = promise; + this._receiver0 = receiver; + if (typeof fulfill === "function") { + this._fulfillmentHandler0 = + domain === null ? fulfill : util.domainBind(domain, fulfill); + } + if (typeof reject === "function") { + this._rejectionHandler0 = + domain === null ? reject : util.domainBind(domain, reject); + } + } else { + var base = index * 4 - 4; + this[base + 2] = promise; + this[base + 3] = receiver; + if (typeof fulfill === "function") { + this[base + 0] = + domain === null ? fulfill : util.domainBind(domain, fulfill); + } + if (typeof reject === "function") { + this[base + 1] = + domain === null ? reject : util.domainBind(domain, reject); + } + } + this._setLength(index + 1); + return index; + }; + + Promise.prototype._proxy = function (proxyable, arg) { + this._addCallbacks(undefined, undefined, arg, proxyable, null); + }; + + Promise.prototype._resolveCallback = function(value, shouldBind) { + if (((this._bitField & 117506048) !== 0)) return; + if (value === this) + return this._rejectCallback(makeSelfResolutionError(), false); + var maybePromise = tryConvertToPromise(value, this); + if (!(maybePromise instanceof Promise)) return this._fulfill(value); + + if (shouldBind) this._propagateFrom(maybePromise, 2); + + var promise = maybePromise._target(); + + if (promise === this) { + this._reject(makeSelfResolutionError()); + return; + } + + var bitField = promise._bitField; + if (((bitField & 50397184) === 0)) { + var len = this._length(); + if (len > 0) promise._migrateCallback0(this); + for (var i = 1; i < len; ++i) { + promise._migrateCallbackAt(this, i); + } + this._setFollowing(); + this._setLength(0); + this._setFollowee(promise); + } else if (((bitField & 33554432) !== 0)) { + this._fulfill(promise._value()); + } else if (((bitField & 16777216) !== 0)) { + this._reject(promise._reason()); + } else { + var reason = new CancellationError("late cancellation observer"); + promise._attachExtraTrace(reason); + this._reject(reason); + } + }; + + Promise.prototype._rejectCallback = + function(reason, synchronous, ignoreNonErrorWarnings) { + var trace = util.ensureErrorObject(reason); + var hasStack = trace === reason; + if (!hasStack && !ignoreNonErrorWarnings && debug.warnings()) { + var message = "a promise was rejected with a non-error: " + + util.classString(reason); + this._warn(message, true); + } + this._attachExtraTrace(trace, synchronous ? hasStack : false); + this._reject(reason); + }; + + Promise.prototype._resolveFromExecutor = function (executor) { + if (executor === INTERNAL) return; + var promise = this; + this._captureStackTrace(); + this._pushContext(); + var synchronous = true; + var r = this._execute(executor, function(value) { + promise._resolveCallback(value); + }, function (reason) { + promise._rejectCallback(reason, synchronous); + }); + synchronous = false; + this._popContext(); + + if (r !== undefined) { + promise._rejectCallback(r, true); + } + }; + + Promise.prototype._settlePromiseFromHandler = function ( + handler, receiver, value, promise + ) { + var bitField = promise._bitField; + if (((bitField & 65536) !== 0)) return; + promise._pushContext(); + var x; + if (receiver === APPLY) { + if (!value || typeof value.length !== "number") { + x = errorObj; + x.e = new TypeError("cannot .spread() a non-array: " + + util.classString(value)); + } else { + x = tryCatch(handler).apply(this._boundValue(), value); + } + } else { + x = tryCatch(handler).call(receiver, value); + } + var promiseCreated = promise._popContext(); + bitField = promise._bitField; + if (((bitField & 65536) !== 0)) return; + + if (x === NEXT_FILTER) { + promise._reject(value); + } else if (x === errorObj) { + promise._rejectCallback(x.e, false); + } else { + debug.checkForgottenReturns(x, promiseCreated, "", promise, this); + promise._resolveCallback(x); + } + }; + + Promise.prototype._target = function() { + var ret = this; + while (ret._isFollowing()) ret = ret._followee(); + return ret; + }; + + Promise.prototype._followee = function() { + return this._rejectionHandler0; + }; + + Promise.prototype._setFollowee = function(promise) { + this._rejectionHandler0 = promise; + }; + + Promise.prototype._settlePromise = function(promise, handler, receiver, value) { + var isPromise = promise instanceof Promise; + var bitField = this._bitField; + var asyncGuaranteed = ((bitField & 134217728) !== 0); + if (((bitField & 65536) !== 0)) { + if (isPromise) promise._invokeInternalOnCancel(); + + if (receiver instanceof PassThroughHandlerContext && + receiver.isFinallyHandler()) { + receiver.cancelPromise = promise; + if (tryCatch(handler).call(receiver, value) === errorObj) { + promise._reject(errorObj.e); + } + } else if (handler === reflectHandler) { + promise._fulfill(reflectHandler.call(receiver)); + } else if (receiver instanceof Proxyable) { + receiver._promiseCancelled(promise); + } else if (isPromise || promise instanceof PromiseArray) { + promise._cancel(); + } else { + receiver.cancel(); + } + } else if (typeof handler === "function") { + if (!isPromise) { + handler.call(receiver, value, promise); + } else { + if (asyncGuaranteed) promise._setAsyncGuaranteed(); + this._settlePromiseFromHandler(handler, receiver, value, promise); + } + } else if (receiver instanceof Proxyable) { + if (!receiver._isResolved()) { + if (((bitField & 33554432) !== 0)) { + receiver._promiseFulfilled(value, promise); + } else { + receiver._promiseRejected(value, promise); + } + } + } else if (isPromise) { + if (asyncGuaranteed) promise._setAsyncGuaranteed(); + if (((bitField & 33554432) !== 0)) { + promise._fulfill(value); + } else { + promise._reject(value); + } + } + }; + + Promise.prototype._settlePromiseLateCancellationObserver = function(ctx) { + var handler = ctx.handler; + var promise = ctx.promise; + var receiver = ctx.receiver; + var value = ctx.value; + if (typeof handler === "function") { + if (!(promise instanceof Promise)) { + handler.call(receiver, value, promise); + } else { + this._settlePromiseFromHandler(handler, receiver, value, promise); + } + } else if (promise instanceof Promise) { + promise._reject(value); + } + }; + + Promise.prototype._settlePromiseCtx = function(ctx) { + this._settlePromise(ctx.promise, ctx.handler, ctx.receiver, ctx.value); + }; + + Promise.prototype._settlePromise0 = function(handler, value, bitField) { + var promise = this._promise0; + var receiver = this._receiverAt(0); + this._promise0 = undefined; + this._receiver0 = undefined; + this._settlePromise(promise, handler, receiver, value); + }; + + Promise.prototype._clearCallbackDataAtIndex = function(index) { + var base = index * 4 - 4; + this[base + 2] = + this[base + 3] = + this[base + 0] = + this[base + 1] = undefined; + }; + + Promise.prototype._fulfill = function (value) { + var bitField = this._bitField; + if (((bitField & 117506048) >>> 16)) return; + if (value === this) { + var err = makeSelfResolutionError(); + this._attachExtraTrace(err); + return this._reject(err); + } + this._setFulfilled(); + this._rejectionHandler0 = value; + + if ((bitField & 65535) > 0) { + if (((bitField & 134217728) !== 0)) { + this._settlePromises(); + } else { + async.settlePromises(this); + } + } + }; + + Promise.prototype._reject = function (reason) { + var bitField = this._bitField; + if (((bitField & 117506048) >>> 16)) return; + this._setRejected(); + this._fulfillmentHandler0 = reason; + + if (this._isFinal()) { + return async.fatalError(reason, util.isNode); + } + + if ((bitField & 65535) > 0) { + async.settlePromises(this); + } else { + this._ensurePossibleRejectionHandled(); + } + }; + + Promise.prototype._fulfillPromises = function (len, value) { + for (var i = 1; i < len; i++) { + var handler = this._fulfillmentHandlerAt(i); + var promise = this._promiseAt(i); + var receiver = this._receiverAt(i); + this._clearCallbackDataAtIndex(i); + this._settlePromise(promise, handler, receiver, value); + } + }; + + Promise.prototype._rejectPromises = function (len, reason) { + for (var i = 1; i < len; i++) { + var handler = this._rejectionHandlerAt(i); + var promise = this._promiseAt(i); + var receiver = this._receiverAt(i); + this._clearCallbackDataAtIndex(i); + this._settlePromise(promise, handler, receiver, reason); + } + }; + + Promise.prototype._settlePromises = function () { + var bitField = this._bitField; + var len = (bitField & 65535); + + if (len > 0) { + if (((bitField & 16842752) !== 0)) { + var reason = this._fulfillmentHandler0; + this._settlePromise0(this._rejectionHandler0, reason, bitField); + this._rejectPromises(len, reason); + } else { + var value = this._rejectionHandler0; + this._settlePromise0(this._fulfillmentHandler0, value, bitField); + this._fulfillPromises(len, value); + } + this._setLength(0); + } + this._clearCancellationData(); + }; + + Promise.prototype._settledValue = function() { + var bitField = this._bitField; + if (((bitField & 33554432) !== 0)) { + return this._rejectionHandler0; + } else if (((bitField & 16777216) !== 0)) { + return this._fulfillmentHandler0; + } + }; + + function deferResolve(v) {this.promise._resolveCallback(v);} + function deferReject(v) {this.promise._rejectCallback(v, false);} + + Promise.defer = Promise.pending = function() { + debug.deprecated("Promise.defer", "new Promise"); + var promise = new Promise(INTERNAL); + return { + promise: promise, + resolve: deferResolve, + reject: deferReject + }; + }; + + util.notEnumerableProp(Promise, + "_makeSelfResolutionError", + makeSelfResolutionError); + + __webpack_require__(20)(Promise, INTERNAL, tryConvertToPromise, apiRejection, + debug); + __webpack_require__(21)(Promise, INTERNAL, tryConvertToPromise, debug); + __webpack_require__(22)(Promise, PromiseArray, apiRejection, debug); + __webpack_require__(23)(Promise); + __webpack_require__(24)(Promise); + __webpack_require__(25)( + Promise, PromiseArray, tryConvertToPromise, INTERNAL, async, getDomain); + Promise.Promise = Promise; + Promise.version = "3.5.1"; + __webpack_require__(26)(Promise, PromiseArray, apiRejection, tryConvertToPromise, INTERNAL, debug); + __webpack_require__(27)(Promise); + __webpack_require__(28)(Promise, apiRejection, tryConvertToPromise, createContext, INTERNAL, debug); + __webpack_require__(29)(Promise, INTERNAL, debug); + __webpack_require__(30)(Promise, apiRejection, INTERNAL, tryConvertToPromise, Proxyable, debug); + __webpack_require__(31)(Promise); + __webpack_require__(32)(Promise, INTERNAL); + __webpack_require__(33)(Promise, PromiseArray, tryConvertToPromise, apiRejection); + __webpack_require__(34)(Promise, INTERNAL, tryConvertToPromise, apiRejection); + __webpack_require__(35)(Promise, PromiseArray, apiRejection, tryConvertToPromise, INTERNAL, debug); + __webpack_require__(36)(Promise, PromiseArray, debug); + __webpack_require__(37)(Promise, PromiseArray, apiRejection); + __webpack_require__(38)(Promise, INTERNAL); + __webpack_require__(39)(Promise, INTERNAL); + __webpack_require__(40)(Promise); + + util.toFastProperties(Promise); + util.toFastProperties(Promise.prototype); + function fillTypes(value) { + var p = new Promise(INTERNAL); + p._fulfillmentHandler0 = value; + p._rejectionHandler0 = value; + p._promise0 = value; + p._receiver0 = value; + } + // Complete slack tracking, opt out of field-type tracking and + // stabilize map + fillTypes({a: 1}); + fillTypes({b: 2}); + fillTypes({c: 3}); + fillTypes(1); + fillTypes(function(){}); + fillTypes(undefined); + fillTypes(false); + fillTypes(new Promise(INTERNAL)); + debug.setBounds(Async.firstLineError, util.lastLineError); + return Promise; + + }; + + /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(4))) + +/***/ }), +/* 4 */ +/***/ (function(module, exports) { + + // shim for using process in browser + var process = module.exports = {}; + + // cached from whatever global is present so that test runners that stub it + // don't break things. But we need to wrap it in a try catch in case it is + // wrapped in strict mode code which doesn't define any globals. It's inside a + // function because try/catches deoptimize in certain engines. + + var cachedSetTimeout; + var cachedClearTimeout; + + function defaultSetTimout() { + throw new Error('setTimeout has not been defined'); + } + function defaultClearTimeout () { + throw new Error('clearTimeout has not been defined'); + } + (function () { + try { + if (typeof setTimeout === 'function') { + cachedSetTimeout = setTimeout; + } else { + cachedSetTimeout = defaultSetTimout; + } + } catch (e) { + cachedSetTimeout = defaultSetTimout; + } + try { + if (typeof clearTimeout === 'function') { + cachedClearTimeout = clearTimeout; + } else { + cachedClearTimeout = defaultClearTimeout; + } + } catch (e) { + cachedClearTimeout = defaultClearTimeout; + } + } ()) + function runTimeout(fun) { + if (cachedSetTimeout === setTimeout) { + //normal enviroments in sane situations + return setTimeout(fun, 0); + } + // if setTimeout wasn't available but was latter defined + if ((cachedSetTimeout === defaultSetTimout || !cachedSetTimeout) && setTimeout) { + cachedSetTimeout = setTimeout; + return setTimeout(fun, 0); + } + try { + // when when somebody has screwed with setTimeout but no I.E. maddness + return cachedSetTimeout(fun, 0); + } catch(e){ + try { + // When we are in I.E. but the script has been evaled so I.E. doesn't trust the global object when called normally + return cachedSetTimeout.call(null, fun, 0); + } catch(e){ + // same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error + return cachedSetTimeout.call(this, fun, 0); + } + } + + + } + function runClearTimeout(marker) { + if (cachedClearTimeout === clearTimeout) { + //normal enviroments in sane situations + return clearTimeout(marker); + } + // if clearTimeout wasn't available but was latter defined + if ((cachedClearTimeout === defaultClearTimeout || !cachedClearTimeout) && clearTimeout) { + cachedClearTimeout = clearTimeout; + return clearTimeout(marker); + } + try { + // when when somebody has screwed with setTimeout but no I.E. maddness + return cachedClearTimeout(marker); + } catch (e){ + try { + // When we are in I.E. but the script has been evaled so I.E. doesn't trust the global object when called normally + return cachedClearTimeout.call(null, marker); + } catch (e){ + // same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error. + // Some versions of I.E. have different rules for clearTimeout vs setTimeout + return cachedClearTimeout.call(this, marker); + } + } + + + + } + var queue = []; + var draining = false; + var currentQueue; + var queueIndex = -1; + + function cleanUpNextTick() { + if (!draining || !currentQueue) { + return; + } + draining = false; + if (currentQueue.length) { + queue = currentQueue.concat(queue); + } else { + queueIndex = -1; + } + if (queue.length) { + drainQueue(); + } + } + + function drainQueue() { + if (draining) { + return; + } + var timeout = runTimeout(cleanUpNextTick); + draining = true; + + var len = queue.length; + while(len) { + currentQueue = queue; + queue = []; + while (++queueIndex < len) { + if (currentQueue) { + currentQueue[queueIndex].run(); + } + } + queueIndex = -1; + len = queue.length; + } + currentQueue = null; + draining = false; + runClearTimeout(timeout); + } + + process.nextTick = function (fun) { + var args = new Array(arguments.length - 1); + if (arguments.length > 1) { + for (var i = 1; i < arguments.length; i++) { + args[i - 1] = arguments[i]; + } + } + queue.push(new Item(fun, args)); + if (queue.length === 1 && !draining) { + runTimeout(drainQueue); + } + }; + + // v8 likes predictible objects + function Item(fun, array) { + this.fun = fun; + this.array = array; + } + Item.prototype.run = function () { + this.fun.apply(null, this.array); + }; + process.title = 'browser'; + process.browser = true; + process.env = {}; + process.argv = []; + process.version = ''; // empty string to avoid regexp issues + process.versions = {}; + + function noop() {} + + process.on = noop; + process.addListener = noop; + process.once = noop; + process.off = noop; + process.removeListener = noop; + process.removeAllListeners = noop; + process.emit = noop; + process.prependListener = noop; + process.prependOnceListener = noop; + + process.listeners = function (name) { return [] } + + process.binding = function (name) { + throw new Error('process.binding is not supported'); + }; + + process.cwd = function () { return '/' }; + process.chdir = function (dir) { + throw new Error('process.chdir is not supported'); + }; + process.umask = function() { return 0; }; + + +/***/ }), +/* 5 */ +/***/ (function(module, exports, __webpack_require__) { + + /* WEBPACK VAR INJECTION */(function(global, process) {"use strict"; + var es5 = __webpack_require__(6); + var canEvaluate = typeof navigator == "undefined"; + + var errorObj = {e: {}}; + var tryCatchTarget; + var globalObject = typeof self !== "undefined" ? self : + typeof window !== "undefined" ? window : + typeof global !== "undefined" ? global : + this !== undefined ? this : null; + + function tryCatcher() { + try { + var target = tryCatchTarget; + tryCatchTarget = null; + return target.apply(this, arguments); + } catch (e) { + errorObj.e = e; + return errorObj; + } + } + function tryCatch(fn) { + tryCatchTarget = fn; + return tryCatcher; + } + + var inherits = function(Child, Parent) { + var hasProp = {}.hasOwnProperty; + + function T() { + this.constructor = Child; + this.constructor$ = Parent; + for (var propertyName in Parent.prototype) { + if (hasProp.call(Parent.prototype, propertyName) && + propertyName.charAt(propertyName.length-1) !== "$" + ) { + this[propertyName + "$"] = Parent.prototype[propertyName]; + } + } + } + T.prototype = Parent.prototype; + Child.prototype = new T(); + return Child.prototype; + }; + + + function isPrimitive(val) { + return val == null || val === true || val === false || + typeof val === "string" || typeof val === "number"; + + } + + function isObject(value) { + return typeof value === "function" || + typeof value === "object" && value !== null; + } + + function maybeWrapAsError(maybeError) { + if (!isPrimitive(maybeError)) return maybeError; + + return new Error(safeToString(maybeError)); + } + + function withAppended(target, appendee) { + var len = target.length; + var ret = new Array(len + 1); + var i; + for (i = 0; i < len; ++i) { + ret[i] = target[i]; + } + ret[i] = appendee; + return ret; + } + + function getDataPropertyOrDefault(obj, key, defaultValue) { + if (es5.isES5) { + var desc = Object.getOwnPropertyDescriptor(obj, key); + + if (desc != null) { + return desc.get == null && desc.set == null + ? desc.value + : defaultValue; + } + } else { + return {}.hasOwnProperty.call(obj, key) ? obj[key] : undefined; + } + } + + function notEnumerableProp(obj, name, value) { + if (isPrimitive(obj)) return obj; + var descriptor = { + value: value, + configurable: true, + enumerable: false, + writable: true + }; + es5.defineProperty(obj, name, descriptor); + return obj; + } + + function thrower(r) { + throw r; + } + + var inheritedDataKeys = (function() { + var excludedPrototypes = [ + Array.prototype, + Object.prototype, + Function.prototype + ]; + + var isExcludedProto = function(val) { + for (var i = 0; i < excludedPrototypes.length; ++i) { + if (excludedPrototypes[i] === val) { + return true; + } + } + return false; + }; + + if (es5.isES5) { + var getKeys = Object.getOwnPropertyNames; + return function(obj) { + var ret = []; + var visitedKeys = Object.create(null); + while (obj != null && !isExcludedProto(obj)) { + var keys; + try { + keys = getKeys(obj); + } catch (e) { + return ret; + } + for (var i = 0; i < keys.length; ++i) { + var key = keys[i]; + if (visitedKeys[key]) continue; + visitedKeys[key] = true; + var desc = Object.getOwnPropertyDescriptor(obj, key); + if (desc != null && desc.get == null && desc.set == null) { + ret.push(key); + } + } + obj = es5.getPrototypeOf(obj); + } + return ret; + }; + } else { + var hasProp = {}.hasOwnProperty; + return function(obj) { + if (isExcludedProto(obj)) return []; + var ret = []; + + /*jshint forin:false */ + enumeration: for (var key in obj) { + if (hasProp.call(obj, key)) { + ret.push(key); + } else { + for (var i = 0; i < excludedPrototypes.length; ++i) { + if (hasProp.call(excludedPrototypes[i], key)) { + continue enumeration; + } + } + ret.push(key); + } + } + return ret; + }; + } + + })(); + + var thisAssignmentPattern = /this\s*\.\s*\S+\s*=/; + function isClass(fn) { + try { + if (typeof fn === "function") { + var keys = es5.names(fn.prototype); + + var hasMethods = es5.isES5 && keys.length > 1; + var hasMethodsOtherThanConstructor = keys.length > 0 && + !(keys.length === 1 && keys[0] === "constructor"); + var hasThisAssignmentAndStaticMethods = + thisAssignmentPattern.test(fn + "") && es5.names(fn).length > 0; + + if (hasMethods || hasMethodsOtherThanConstructor || + hasThisAssignmentAndStaticMethods) { + return true; + } + } + return false; + } catch (e) { + return false; + } + } + + function toFastProperties(obj) { + /*jshint -W027,-W055,-W031*/ + function FakeConstructor() {} + FakeConstructor.prototype = obj; + var l = 8; + while (l--) new FakeConstructor(); + return obj; + eval(obj); + } + + var rident = /^[a-z$_][a-z$_0-9]*$/i; + function isIdentifier(str) { + return rident.test(str); + } + + function filledRange(count, prefix, suffix) { + var ret = new Array(count); + for(var i = 0; i < count; ++i) { + ret[i] = prefix + i + suffix; + } + return ret; + } + + function safeToString(obj) { + try { + return obj + ""; + } catch (e) { + return "[no string representation]"; + } + } + + function isError(obj) { + return obj instanceof Error || + (obj !== null && + typeof obj === "object" && + typeof obj.message === "string" && + typeof obj.name === "string"); + } + + function markAsOriginatingFromRejection(e) { + try { + notEnumerableProp(e, "isOperational", true); + } + catch(ignore) {} + } + + function originatesFromRejection(e) { + if (e == null) return false; + return ((e instanceof Error["__BluebirdErrorTypes__"].OperationalError) || + e["isOperational"] === true); + } + + function canAttachTrace(obj) { + return isError(obj) && es5.propertyIsWritable(obj, "stack"); + } + + var ensureErrorObject = (function() { + if (!("stack" in new Error())) { + return function(value) { + if (canAttachTrace(value)) return value; + try {throw new Error(safeToString(value));} + catch(err) {return err;} + }; + } else { + return function(value) { + if (canAttachTrace(value)) return value; + return new Error(safeToString(value)); + }; + } + })(); + + function classString(obj) { + return {}.toString.call(obj); + } + + function copyDescriptors(from, to, filter) { + var keys = es5.names(from); + for (var i = 0; i < keys.length; ++i) { + var key = keys[i]; + if (filter(key)) { + try { + es5.defineProperty(to, key, es5.getDescriptor(from, key)); + } catch (ignore) {} + } + } + } + + var asArray = function(v) { + if (es5.isArray(v)) { + return v; + } + return null; + }; + + if (typeof Symbol !== "undefined" && Symbol.iterator) { + var ArrayFrom = typeof Array.from === "function" ? function(v) { + return Array.from(v); + } : function(v) { + var ret = []; + var it = v[Symbol.iterator](); + var itResult; + while (!((itResult = it.next()).done)) { + ret.push(itResult.value); + } + return ret; + }; + + asArray = function(v) { + if (es5.isArray(v)) { + return v; + } else if (v != null && typeof v[Symbol.iterator] === "function") { + return ArrayFrom(v); + } + return null; + }; + } + + var isNode = typeof process !== "undefined" && + classString(process).toLowerCase() === "[object process]"; + + var hasEnvVariables = typeof process !== "undefined" && + typeof process.env !== "undefined"; + + function env(key) { + return hasEnvVariables ? process.env[key] : undefined; + } + + function getNativePromise() { + if (typeof Promise === "function") { + try { + var promise = new Promise(function(){}); + if ({}.toString.call(promise) === "[object Promise]") { + return Promise; + } + } catch (e) {} + } + } + + function domainBind(self, cb) { + return self.bind(cb); + } + + var ret = { + isClass: isClass, + isIdentifier: isIdentifier, + inheritedDataKeys: inheritedDataKeys, + getDataPropertyOrDefault: getDataPropertyOrDefault, + thrower: thrower, + isArray: es5.isArray, + asArray: asArray, + notEnumerableProp: notEnumerableProp, + isPrimitive: isPrimitive, + isObject: isObject, + isError: isError, + canEvaluate: canEvaluate, + errorObj: errorObj, + tryCatch: tryCatch, + inherits: inherits, + withAppended: withAppended, + maybeWrapAsError: maybeWrapAsError, + toFastProperties: toFastProperties, + filledRange: filledRange, + toString: safeToString, + canAttachTrace: canAttachTrace, + ensureErrorObject: ensureErrorObject, + originatesFromRejection: originatesFromRejection, + markAsOriginatingFromRejection: markAsOriginatingFromRejection, + classString: classString, + copyDescriptors: copyDescriptors, + hasDevTools: typeof chrome !== "undefined" && chrome && + typeof chrome.loadTimes === "function", + isNode: isNode, + hasEnvVariables: hasEnvVariables, + env: env, + global: globalObject, + getNativePromise: getNativePromise, + domainBind: domainBind + }; + ret.isRecentNode = ret.isNode && (function() { + var version = process.versions.node.split(".").map(Number); + return (version[0] === 0 && version[1] > 10) || (version[0] > 0); + })(); + + if (ret.isNode) ret.toFastProperties(process); + + try {throw new Error(); } catch (e) {ret.lastLineError = e;} + module.exports = ret; + + /* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }()), __webpack_require__(4))) + +/***/ }), +/* 6 */ +/***/ (function(module, exports) { + + var isES5 = (function(){ + "use strict"; + return this === undefined; + })(); + + if (isES5) { + module.exports = { + freeze: Object.freeze, + defineProperty: Object.defineProperty, + getDescriptor: Object.getOwnPropertyDescriptor, + keys: Object.keys, + names: Object.getOwnPropertyNames, + getPrototypeOf: Object.getPrototypeOf, + isArray: Array.isArray, + isES5: isES5, + propertyIsWritable: function(obj, prop) { + var descriptor = Object.getOwnPropertyDescriptor(obj, prop); + return !!(!descriptor || descriptor.writable || descriptor.set); + } + }; + } else { + var has = {}.hasOwnProperty; + var str = {}.toString; + var proto = {}.constructor.prototype; + + var ObjectKeys = function (o) { + var ret = []; + for (var key in o) { + if (has.call(o, key)) { + ret.push(key); + } + } + return ret; + }; + + var ObjectGetDescriptor = function(o, key) { + return {value: o[key]}; + }; + + var ObjectDefineProperty = function (o, key, desc) { + o[key] = desc.value; + return o; + }; + + var ObjectFreeze = function (obj) { + return obj; + }; + + var ObjectGetPrototypeOf = function (obj) { + try { + return Object(obj).constructor.prototype; + } + catch (e) { + return proto; + } + }; + + var ArrayIsArray = function (obj) { + try { + return str.call(obj) === "[object Array]"; + } + catch(e) { + return false; + } + }; + + module.exports = { + isArray: ArrayIsArray, + keys: ObjectKeys, + names: ObjectKeys, + defineProperty: ObjectDefineProperty, + getDescriptor: ObjectGetDescriptor, + freeze: ObjectFreeze, + getPrototypeOf: ObjectGetPrototypeOf, + isES5: isES5, + propertyIsWritable: function() { + return true; + } + }; + } + + +/***/ }), +/* 7 */ +/***/ (function(module, exports, __webpack_require__) { + + /* WEBPACK VAR INJECTION */(function(process) {"use strict"; + var firstLineError; + try {throw new Error(); } catch (e) {firstLineError = e;} + var schedule = __webpack_require__(8); + var Queue = __webpack_require__(11); + var util = __webpack_require__(5); + + function Async() { + this._customScheduler = false; + this._isTickUsed = false; + this._lateQueue = new Queue(16); + this._normalQueue = new Queue(16); + this._haveDrainedQueues = false; + this._trampolineEnabled = true; + var self = this; + this.drainQueues = function () { + self._drainQueues(); + }; + this._schedule = schedule; + } + + Async.prototype.setScheduler = function(fn) { + var prev = this._schedule; + this._schedule = fn; + this._customScheduler = true; + return prev; + }; + + Async.prototype.hasCustomScheduler = function() { + return this._customScheduler; + }; + + Async.prototype.enableTrampoline = function() { + this._trampolineEnabled = true; + }; + + Async.prototype.disableTrampolineIfNecessary = function() { + if (util.hasDevTools) { + this._trampolineEnabled = false; + } + }; + + Async.prototype.haveItemsQueued = function () { + return this._isTickUsed || this._haveDrainedQueues; + }; + + + Async.prototype.fatalError = function(e, isNode) { + if (isNode) { + process.stderr.write("Fatal " + (e instanceof Error ? e.stack : e) + + "\n"); + process.exit(2); + } else { + this.throwLater(e); + } + }; + + Async.prototype.throwLater = function(fn, arg) { + if (arguments.length === 1) { + arg = fn; + fn = function () { throw arg; }; + } + if (typeof setTimeout !== "undefined") { + setTimeout(function() { + fn(arg); + }, 0); + } else try { + this._schedule(function() { + fn(arg); + }); + } catch (e) { + throw new Error("No async scheduler available\u000a\u000a See http://goo.gl/MqrFmX\u000a"); + } + }; + + function AsyncInvokeLater(fn, receiver, arg) { + this._lateQueue.push(fn, receiver, arg); + this._queueTick(); + } + + function AsyncInvoke(fn, receiver, arg) { + this._normalQueue.push(fn, receiver, arg); + this._queueTick(); + } + + function AsyncSettlePromises(promise) { + this._normalQueue._pushOne(promise); + this._queueTick(); + } + + if (!util.hasDevTools) { + Async.prototype.invokeLater = AsyncInvokeLater; + Async.prototype.invoke = AsyncInvoke; + Async.prototype.settlePromises = AsyncSettlePromises; + } else { + Async.prototype.invokeLater = function (fn, receiver, arg) { + if (this._trampolineEnabled) { + AsyncInvokeLater.call(this, fn, receiver, arg); + } else { + this._schedule(function() { + setTimeout(function() { + fn.call(receiver, arg); + }, 100); + }); + } + }; + + Async.prototype.invoke = function (fn, receiver, arg) { + if (this._trampolineEnabled) { + AsyncInvoke.call(this, fn, receiver, arg); + } else { + this._schedule(function() { + fn.call(receiver, arg); + }); + } + }; + + Async.prototype.settlePromises = function(promise) { + if (this._trampolineEnabled) { + AsyncSettlePromises.call(this, promise); + } else { + this._schedule(function() { + promise._settlePromises(); + }); + } + }; + } + + Async.prototype._drainQueue = function(queue) { + while (queue.length() > 0) { + var fn = queue.shift(); + if (typeof fn !== "function") { + fn._settlePromises(); + continue; + } + var receiver = queue.shift(); + var arg = queue.shift(); + fn.call(receiver, arg); + } + }; + + Async.prototype._drainQueues = function () { + this._drainQueue(this._normalQueue); + this._reset(); + this._haveDrainedQueues = true; + this._drainQueue(this._lateQueue); + }; + + Async.prototype._queueTick = function () { + if (!this._isTickUsed) { + this._isTickUsed = true; + this._schedule(this.drainQueues); + } + }; + + Async.prototype._reset = function () { + this._isTickUsed = false; + }; + + module.exports = Async; + module.exports.firstLineError = firstLineError; + + /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(4))) + +/***/ }), +/* 8 */ +/***/ (function(module, exports, __webpack_require__) { + + /* WEBPACK VAR INJECTION */(function(global, process, setImmediate) {"use strict"; + var util = __webpack_require__(5); + var schedule; + var noAsyncScheduler = function() { + throw new Error("No async scheduler available\u000a\u000a See http://goo.gl/MqrFmX\u000a"); + }; + var NativePromise = util.getNativePromise(); + if (util.isNode && typeof MutationObserver === "undefined") { + var GlobalSetImmediate = global.setImmediate; + var ProcessNextTick = process.nextTick; + schedule = util.isRecentNode + ? function(fn) { GlobalSetImmediate.call(global, fn); } + : function(fn) { ProcessNextTick.call(process, fn); }; + } else if (typeof NativePromise === "function" && + typeof NativePromise.resolve === "function") { + var nativePromise = NativePromise.resolve(); + schedule = function(fn) { + nativePromise.then(fn); + }; + } else if ((typeof MutationObserver !== "undefined") && + !(typeof window !== "undefined" && + window.navigator && + (window.navigator.standalone || window.cordova))) { + schedule = (function() { + var div = document.createElement("div"); + var opts = {attributes: true}; + var toggleScheduled = false; + var div2 = document.createElement("div"); + var o2 = new MutationObserver(function() { + div.classList.toggle("foo"); + toggleScheduled = false; + }); + o2.observe(div2, opts); + + var scheduleToggle = function() { + if (toggleScheduled) return; + toggleScheduled = true; + div2.classList.toggle("foo"); + }; + + return function schedule(fn) { + var o = new MutationObserver(function() { + o.disconnect(); + fn(); + }); + o.observe(div, opts); + scheduleToggle(); + }; + })(); + } else if (typeof setImmediate !== "undefined") { + schedule = function (fn) { + setImmediate(fn); + }; + } else if (typeof setTimeout !== "undefined") { + schedule = function (fn) { + setTimeout(fn, 0); + }; + } else { + schedule = noAsyncScheduler; + } + module.exports = schedule; + + /* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }()), __webpack_require__(4), __webpack_require__(9).setImmediate)) + +/***/ }), +/* 9 */ +/***/ (function(module, exports, __webpack_require__) { + + var apply = Function.prototype.apply; + + // DOM APIs, for completeness + + exports.setTimeout = function() { + return new Timeout(apply.call(setTimeout, window, arguments), clearTimeout); + }; + exports.setInterval = function() { + return new Timeout(apply.call(setInterval, window, arguments), clearInterval); + }; + exports.clearTimeout = + exports.clearInterval = function(timeout) { + if (timeout) { + timeout.close(); + } + }; + + function Timeout(id, clearFn) { + this._id = id; + this._clearFn = clearFn; + } + Timeout.prototype.unref = Timeout.prototype.ref = function() {}; + Timeout.prototype.close = function() { + this._clearFn.call(window, this._id); + }; + + // Does not start the time, just sets up the members needed. + exports.enroll = function(item, msecs) { + clearTimeout(item._idleTimeoutId); + item._idleTimeout = msecs; + }; + + exports.unenroll = function(item) { + clearTimeout(item._idleTimeoutId); + item._idleTimeout = -1; + }; + + exports._unrefActive = exports.active = function(item) { + clearTimeout(item._idleTimeoutId); + + var msecs = item._idleTimeout; + if (msecs >= 0) { + item._idleTimeoutId = setTimeout(function onTimeout() { + if (item._onTimeout) + item._onTimeout(); + }, msecs); + } + }; + + // setimmediate attaches itself to the global object + __webpack_require__(10); + exports.setImmediate = setImmediate; + exports.clearImmediate = clearImmediate; + + +/***/ }), +/* 10 */ +/***/ (function(module, exports, __webpack_require__) { + + /* WEBPACK VAR INJECTION */(function(global, process) {(function (global, undefined) { + "use strict"; + + if (global.setImmediate) { + return; + } + + var nextHandle = 1; // Spec says greater than zero + var tasksByHandle = {}; + var currentlyRunningATask = false; + var doc = global.document; + var registerImmediate; + + function setImmediate(callback) { + // Callback can either be a function or a string + if (typeof callback !== "function") { + callback = new Function("" + callback); + } + // Copy function arguments + var args = new Array(arguments.length - 1); + for (var i = 0; i < args.length; i++) { + args[i] = arguments[i + 1]; + } + // Store and register the task + var task = { callback: callback, args: args }; + tasksByHandle[nextHandle] = task; + registerImmediate(nextHandle); + return nextHandle++; + } + + function clearImmediate(handle) { + delete tasksByHandle[handle]; + } + + function run(task) { + var callback = task.callback; + var args = task.args; + switch (args.length) { + case 0: + callback(); + break; + case 1: + callback(args[0]); + break; + case 2: + callback(args[0], args[1]); + break; + case 3: + callback(args[0], args[1], args[2]); + break; + default: + callback.apply(undefined, args); + break; + } + } + + function runIfPresent(handle) { + // From the spec: "Wait until any invocations of this algorithm started before this one have completed." + // So if we're currently running a task, we'll need to delay this invocation. + if (currentlyRunningATask) { + // Delay by doing a setTimeout. setImmediate was tried instead, but in Firefox 7 it generated a + // "too much recursion" error. + setTimeout(runIfPresent, 0, handle); + } else { + var task = tasksByHandle[handle]; + if (task) { + currentlyRunningATask = true; + try { + run(task); + } finally { + clearImmediate(handle); + currentlyRunningATask = false; + } + } + } + } + + function installNextTickImplementation() { + registerImmediate = function(handle) { + process.nextTick(function () { runIfPresent(handle); }); + }; + } + + function canUsePostMessage() { + // The test against `importScripts` prevents this implementation from being installed inside a web worker, + // where `global.postMessage` means something completely different and can't be used for this purpose. + if (global.postMessage && !global.importScripts) { + var postMessageIsAsynchronous = true; + var oldOnMessage = global.onmessage; + global.onmessage = function() { + postMessageIsAsynchronous = false; + }; + global.postMessage("", "*"); + global.onmessage = oldOnMessage; + return postMessageIsAsynchronous; + } + } + + function installPostMessageImplementation() { + // Installs an event handler on `global` for the `message` event: see + // * https://developer.mozilla.org/en/DOM/window.postMessage + // * http://www.whatwg.org/specs/web-apps/current-work/multipage/comms.html#crossDocumentMessages + + var messagePrefix = "setImmediate$" + Math.random() + "$"; + var onGlobalMessage = function(event) { + if (event.source === global && + typeof event.data === "string" && + event.data.indexOf(messagePrefix) === 0) { + runIfPresent(+event.data.slice(messagePrefix.length)); + } + }; + + if (global.addEventListener) { + global.addEventListener("message", onGlobalMessage, false); + } else { + global.attachEvent("onmessage", onGlobalMessage); + } + + registerImmediate = function(handle) { + global.postMessage(messagePrefix + handle, "*"); + }; + } + + function installMessageChannelImplementation() { + var channel = new MessageChannel(); + channel.port1.onmessage = function(event) { + var handle = event.data; + runIfPresent(handle); + }; + + registerImmediate = function(handle) { + channel.port2.postMessage(handle); + }; + } + + function installReadyStateChangeImplementation() { + var html = doc.documentElement; + registerImmediate = function(handle) { + // Create a