diff --git a/examples_proto/05/README.md b/examples_proto/05/README.md
index 93970bd..ec0c1dc 100644
--- a/examples_proto/05/README.md
+++ b/examples_proto/05/README.md
@@ -6,4 +6,4 @@ Shaping functions is fundamental technique that is recursively used throughout t
Read [Shaping functions](../05) to learn more.
-
\ No newline at end of file
+
\ No newline at end of file
diff --git a/examples_proto/06/README.md b/examples_proto/06/README.md
index 1b42575..225e9ef 100644
--- a/examples_proto/06/README.md
+++ b/examples_proto/06/README.md
@@ -7,4 +7,4 @@ In GLSL, colors are simply just vectors, which means you can easily apply the co
Read [Colors](../06) to learn more.
-
\ No newline at end of file
+
\ No newline at end of file
diff --git a/examples_proto/07/README.md b/examples_proto/07/README.md
index 7794a6c..76d2041 100644
--- a/examples_proto/07/README.md
+++ b/examples_proto/07/README.md
@@ -6,4 +6,4 @@ Let's look at how to draw simple shapes in a parallel procedural way. In a nutsh
Read [Shapes](../07) to learn more.
-
\ No newline at end of file
+
\ No newline at end of file
diff --git a/examples_proto/08/README.md b/examples_proto/08/README.md
index 808ff8b..1953156 100644
--- a/examples_proto/08/README.md
+++ b/examples_proto/08/README.md
@@ -7,4 +7,4 @@ Matrices may look complex at a first glance, but you'll find it very handy and u
Read [Matrix](../08) to learn more.
-
+
diff --git a/examples_proto/09/README.md b/examples_proto/09/README.md
index fc3b1e6..aeed911 100644
--- a/examples_proto/09/README.md
+++ b/examples_proto/09/README.md
@@ -6,4 +6,4 @@ Repetitive patterns are perfect theme for computational sketching. Different fro
Read [Patterns](../09) to learn more.
-
+
diff --git a/examples_proto/10/README.md b/examples_proto/10/README.md
index 0f4571e..51b0a43 100644
--- a/examples_proto/10/README.md
+++ b/examples_proto/10/README.md
@@ -6,4 +6,4 @@ Life is boring if everything was predictable. Though nothing is truly random in
Read [Random](../10) to learn more.
-
\ No newline at end of file
+
\ No newline at end of file
diff --git a/examples_proto/11/README.md b/examples_proto/11/README.md
index a4ac13f..b09d09c 100644
--- a/examples_proto/11/README.md
+++ b/examples_proto/11/README.md
@@ -7,4 +7,4 @@ Since Ken Perlin invented his first noise algorithm in 80s, the technique has be
Read [Noise](../11) to learn more.
-
\ No newline at end of file
+
\ No newline at end of file
diff --git a/examples_proto/advanced/README.md b/examples_proto/advanced/README.md
index 7b400c3..eec00d4 100644
--- a/examples_proto/advanced/README.md
+++ b/examples_proto/advanced/README.md
@@ -4,4 +4,4 @@
In this section, we gathered relatively advanced examples from different chapters. Try if you can read and understand all the examples here to test yourself.
-
\ No newline at end of file
+
\ No newline at end of file
diff --git a/examples_proto/header.php b/examples_proto/header.php
index f5e2975..acaa074 100644
--- a/examples_proto/header.php
+++ b/examples_proto/header.php
@@ -27,8 +27,8 @@ echo '
-
+
diff --git a/examples_proto/src/_glslGallery.js b/examples_proto/src/_glslGallery.js
new file mode 100644
index 0000000..e329839
--- /dev/null
+++ b/examples_proto/src/_glslGallery.js
@@ -0,0 +1,4069 @@
+(function(f){if(typeof exports==="object"&&typeof module!=="undefined"){module.exports=f()}else if(typeof define==="function"&&define.amd){define([],f)}else{var g;if(typeof window!=="undefined"){g=window}else if(typeof global!=="undefined"){g=global}else if(typeof self!=="undefined"){g=self}else{g=this}g.glslGallery = f()}})(function(){var define,module,exports;return (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 1 ? arguments[1] : undefined, 3)
+ , entry;
+ while(entry = entry ? entry.n : this._f){
+ f(entry.v, entry.k, this);
+ // revert to the last existing entry
+ while(entry && entry.r)entry = entry.p;
+ }
+ },
+ // 23.1.3.7 Map.prototype.has(key)
+ // 23.2.3.7 Set.prototype.has(value)
+ has: function has(key){
+ return !!getEntry(this, key);
+ }
+ });
+ if(DESCRIPTORS)$.setDesc(C.prototype, 'size', {
+ get: function(){
+ return defined(this[SIZE]);
+ }
+ });
+ return C;
+ },
+ def: function(that, key, value){
+ var entry = getEntry(that, key)
+ , prev, index;
+ // change existing entry
+ if(entry){
+ entry.v = value;
+ // create new entry
+ } else {
+ that._l = entry = {
+ i: index = fastKey(key, true), // <- index
+ k: key, // <- key
+ v: value, // <- value
+ p: prev = that._l, // <- previous entry
+ n: undefined, // <- next entry
+ r: false // <- removed
+ };
+ if(!that._f)that._f = entry;
+ if(prev)prev.n = entry;
+ that[SIZE]++;
+ // add to index
+ if(index !== 'F')that._i[index] = entry;
+ } return that;
+ },
+ getEntry: getEntry,
+ setStrong: function(C, NAME, IS_MAP){
+ // add .keys, .values, .entries, [@@iterator]
+ // 23.1.3.4, 23.1.3.8, 23.1.3.11, 23.1.3.12, 23.2.3.5, 23.2.3.8, 23.2.3.10, 23.2.3.11
+ $iterDefine(C, NAME, function(iterated, kind){
+ this._t = iterated; // target
+ this._k = kind; // kind
+ this._l = undefined; // previous
+ }, function(){
+ var that = this
+ , kind = that._k
+ , entry = that._l;
+ // revert to the last existing entry
+ while(entry && entry.r)entry = entry.p;
+ // get next entry
+ if(!that._t || !(that._l = entry = entry ? entry.n : that._t._f)){
+ // or finish the iteration
+ that._t = undefined;
+ return step(1);
+ }
+ // return step by kind
+ if(kind == 'keys' )return step(0, entry.k);
+ if(kind == 'values')return step(0, entry.v);
+ return step(0, [entry.k, entry.v]);
+ }, IS_MAP ? 'entries' : 'values' , !IS_MAP, true);
+
+ // add [@@species], 23.1.2.2, 23.2.2.2
+ setSpecies(NAME);
+ }
+};
+},{"./$":49,"./$.ctx":28,"./$.defined":29,"./$.descriptors":30,"./$.for-of":34,"./$.has":36,"./$.hide":37,"./$.is-object":42,"./$.iter-define":45,"./$.iter-step":47,"./$.redefine-all":55,"./$.set-species":59,"./$.strict-new":63,"./$.uid":70}],25:[function(_dereq_,module,exports){
+// https://github.com/DavidBruant/Map-Set.prototype.toJSON
+var forOf = _dereq_('./$.for-of')
+ , classof = _dereq_('./$.classof');
+module.exports = function(NAME){
+ return function toJSON(){
+ if(classof(this) != NAME)throw TypeError(NAME + "#toJSON isn't generic");
+ var arr = [];
+ forOf(this, false, arr.push, arr);
+ return arr;
+ };
+};
+},{"./$.classof":22,"./$.for-of":34}],26:[function(_dereq_,module,exports){
+'use strict';
+var $ = _dereq_('./$')
+ , global = _dereq_('./$.global')
+ , $export = _dereq_('./$.export')
+ , fails = _dereq_('./$.fails')
+ , hide = _dereq_('./$.hide')
+ , redefineAll = _dereq_('./$.redefine-all')
+ , forOf = _dereq_('./$.for-of')
+ , strictNew = _dereq_('./$.strict-new')
+ , isObject = _dereq_('./$.is-object')
+ , setToStringTag = _dereq_('./$.set-to-string-tag')
+ , DESCRIPTORS = _dereq_('./$.descriptors');
+
+module.exports = function(NAME, wrapper, methods, common, IS_MAP, IS_WEAK){
+ var Base = global[NAME]
+ , C = Base
+ , ADDER = IS_MAP ? 'set' : 'add'
+ , proto = C && C.prototype
+ , O = {};
+ if(!DESCRIPTORS || typeof C != 'function' || !(IS_WEAK || proto.forEach && !fails(function(){
+ new C().entries().next();
+ }))){
+ // create collection constructor
+ C = common.getConstructor(wrapper, NAME, IS_MAP, ADDER);
+ redefineAll(C.prototype, methods);
+ } else {
+ C = wrapper(function(target, iterable){
+ strictNew(target, C, NAME);
+ target._c = new Base;
+ if(iterable != undefined)forOf(iterable, IS_MAP, target[ADDER], target);
+ });
+ $.each.call('add,clear,delete,forEach,get,has,set,keys,values,entries'.split(','),function(KEY){
+ var IS_ADDER = KEY == 'add' || KEY == 'set';
+ if(KEY in proto && !(IS_WEAK && KEY == 'clear'))hide(C.prototype, KEY, function(a, b){
+ if(!IS_ADDER && IS_WEAK && !isObject(a))return KEY == 'get' ? undefined : false;
+ var result = this._c[KEY](a === 0 ? 0 : a, b);
+ return IS_ADDER ? this : result;
+ });
+ });
+ if('size' in proto)$.setDesc(C.prototype, 'size', {
+ get: function(){
+ return this._c.size;
+ }
+ });
+ }
+
+ setToStringTag(C, NAME);
+
+ O[NAME] = C;
+ $export($export.G + $export.W + $export.F, O);
+
+ if(!IS_WEAK)common.setStrong(C, NAME, IS_MAP);
+
+ return C;
+};
+},{"./$":49,"./$.descriptors":30,"./$.export":32,"./$.fails":33,"./$.for-of":34,"./$.global":35,"./$.hide":37,"./$.is-object":42,"./$.redefine-all":55,"./$.set-to-string-tag":60,"./$.strict-new":63}],27:[function(_dereq_,module,exports){
+var core = module.exports = {version: '1.2.6'};
+if(typeof __e == 'number')__e = core; // eslint-disable-line no-undef
+},{}],28:[function(_dereq_,module,exports){
+// optional / simple context binding
+var aFunction = _dereq_('./$.a-function');
+module.exports = function(fn, that, length){
+ aFunction(fn);
+ if(that === undefined)return fn;
+ switch(length){
+ case 1: return function(a){
+ return fn.call(that, a);
+ };
+ case 2: return function(a, b){
+ return fn.call(that, a, b);
+ };
+ case 3: return function(a, b, c){
+ return fn.call(that, a, b, c);
+ };
+ }
+ return function(/* ...args */){
+ return fn.apply(that, arguments);
+ };
+};
+},{"./$.a-function":19}],29:[function(_dereq_,module,exports){
+// 7.2.1 RequireObjectCoercible(argument)
+module.exports = function(it){
+ if(it == undefined)throw TypeError("Can't call method on " + it);
+ return it;
+};
+},{}],30:[function(_dereq_,module,exports){
+// Thank's IE8 for his funny defineProperty
+module.exports = !_dereq_('./$.fails')(function(){
+ return Object.defineProperty({}, 'a', {get: function(){ return 7; }}).a != 7;
+});
+},{"./$.fails":33}],31:[function(_dereq_,module,exports){
+var isObject = _dereq_('./$.is-object')
+ , document = _dereq_('./$.global').document
+ // in old IE typeof document.createElement is 'object'
+ , is = isObject(document) && isObject(document.createElement);
+module.exports = function(it){
+ return is ? document.createElement(it) : {};
+};
+},{"./$.global":35,"./$.is-object":42}],32:[function(_dereq_,module,exports){
+var global = _dereq_('./$.global')
+ , core = _dereq_('./$.core')
+ , ctx = _dereq_('./$.ctx')
+ , PROTOTYPE = 'prototype';
+
+var $export = function(type, name, source){
+ var IS_FORCED = type & $export.F
+ , IS_GLOBAL = type & $export.G
+ , IS_STATIC = type & $export.S
+ , IS_PROTO = type & $export.P
+ , IS_BIND = type & $export.B
+ , IS_WRAP = type & $export.W
+ , exports = IS_GLOBAL ? core : core[name] || (core[name] = {})
+ , target = IS_GLOBAL ? global : IS_STATIC ? global[name] : (global[name] || {})[PROTOTYPE]
+ , key, own, out;
+ if(IS_GLOBAL)source = name;
+ for(key in source){
+ // contains in native
+ own = !IS_FORCED && target && key in target;
+ if(own && key in exports)continue;
+ // export native or passed
+ out = own ? target[key] : source[key];
+ // prevent global pollution for namespaces
+ exports[key] = IS_GLOBAL && typeof target[key] != 'function' ? source[key]
+ // bind timers to global for call from export context
+ : IS_BIND && own ? ctx(out, global)
+ // wrap global constructors for prevent change them in library
+ : IS_WRAP && target[key] == out ? (function(C){
+ var F = function(param){
+ return this instanceof C ? new C(param) : C(param);
+ };
+ F[PROTOTYPE] = C[PROTOTYPE];
+ return F;
+ // make static versions for prototype methods
+ })(out) : IS_PROTO && typeof out == 'function' ? ctx(Function.call, out) : out;
+ if(IS_PROTO)(exports[PROTOTYPE] || (exports[PROTOTYPE] = {}))[key] = out;
+ }
+};
+// type bitmap
+$export.F = 1; // forced
+$export.G = 2; // global
+$export.S = 4; // static
+$export.P = 8; // proto
+$export.B = 16; // bind
+$export.W = 32; // wrap
+module.exports = $export;
+},{"./$.core":27,"./$.ctx":28,"./$.global":35}],33:[function(_dereq_,module,exports){
+module.exports = function(exec){
+ try {
+ return !!exec();
+ } catch(e){
+ return true;
+ }
+};
+},{}],34:[function(_dereq_,module,exports){
+var ctx = _dereq_('./$.ctx')
+ , call = _dereq_('./$.iter-call')
+ , isArrayIter = _dereq_('./$.is-array-iter')
+ , anObject = _dereq_('./$.an-object')
+ , toLength = _dereq_('./$.to-length')
+ , getIterFn = _dereq_('./core.get-iterator-method');
+module.exports = function(iterable, entries, fn, that){
+ var iterFn = getIterFn(iterable)
+ , f = ctx(fn, that, entries ? 2 : 1)
+ , index = 0
+ , length, step, iterator;
+ if(typeof iterFn != 'function')throw TypeError(iterable + ' is not iterable!');
+ // fast case for arrays with default iterator
+ if(isArrayIter(iterFn))for(length = toLength(iterable.length); length > index; index++){
+ entries ? f(anObject(step = iterable[index])[0], step[1]) : f(iterable[index]);
+ } else for(iterator = iterFn.call(iterable); !(step = iterator.next()).done; ){
+ call(iterator, f, step.value, entries);
+ }
+};
+},{"./$.an-object":21,"./$.ctx":28,"./$.is-array-iter":41,"./$.iter-call":43,"./$.to-length":68,"./core.get-iterator-method":72}],35:[function(_dereq_,module,exports){
+// https://github.com/zloirock/core-js/issues/86#issuecomment-115759028
+var global = module.exports = typeof window != 'undefined' && window.Math == Math
+ ? window : typeof self != 'undefined' && self.Math == Math ? self : Function('return this')();
+if(typeof __g == 'number')__g = global; // eslint-disable-line no-undef
+},{}],36:[function(_dereq_,module,exports){
+var hasOwnProperty = {}.hasOwnProperty;
+module.exports = function(it, key){
+ return hasOwnProperty.call(it, key);
+};
+},{}],37:[function(_dereq_,module,exports){
+var $ = _dereq_('./$')
+ , createDesc = _dereq_('./$.property-desc');
+module.exports = _dereq_('./$.descriptors') ? function(object, key, value){
+ return $.setDesc(object, key, createDesc(1, value));
+} : function(object, key, value){
+ object[key] = value;
+ return object;
+};
+},{"./$":49,"./$.descriptors":30,"./$.property-desc":54}],38:[function(_dereq_,module,exports){
+module.exports = _dereq_('./$.global').document && document.documentElement;
+},{"./$.global":35}],39:[function(_dereq_,module,exports){
+// fast apply, http://jsperf.lnkit.com/fast-apply/5
+module.exports = function(fn, args, that){
+ var un = that === undefined;
+ switch(args.length){
+ case 0: return un ? fn()
+ : fn.call(that);
+ case 1: return un ? fn(args[0])
+ : fn.call(that, args[0]);
+ case 2: return un ? fn(args[0], args[1])
+ : fn.call(that, args[0], args[1]);
+ case 3: return un ? fn(args[0], args[1], args[2])
+ : fn.call(that, args[0], args[1], args[2]);
+ case 4: return un ? fn(args[0], args[1], args[2], args[3])
+ : fn.call(that, args[0], args[1], args[2], args[3]);
+ } return fn.apply(that, args);
+};
+},{}],40:[function(_dereq_,module,exports){
+// fallback for non-array-like ES3 and non-enumerable old V8 strings
+var cof = _dereq_('./$.cof');
+module.exports = Object('z').propertyIsEnumerable(0) ? Object : function(it){
+ return cof(it) == 'String' ? it.split('') : Object(it);
+};
+},{"./$.cof":23}],41:[function(_dereq_,module,exports){
+// check on default Array iterator
+var Iterators = _dereq_('./$.iterators')
+ , ITERATOR = _dereq_('./$.wks')('iterator')
+ , ArrayProto = Array.prototype;
+
+module.exports = function(it){
+ return it !== undefined && (Iterators.Array === it || ArrayProto[ITERATOR] === it);
+};
+},{"./$.iterators":48,"./$.wks":71}],42:[function(_dereq_,module,exports){
+module.exports = function(it){
+ return typeof it === 'object' ? it !== null : typeof it === 'function';
+};
+},{}],43:[function(_dereq_,module,exports){
+// call something on iterator step with safe closing on error
+var anObject = _dereq_('./$.an-object');
+module.exports = function(iterator, fn, value, entries){
+ try {
+ return entries ? fn(anObject(value)[0], value[1]) : fn(value);
+ // 7.4.6 IteratorClose(iterator, completion)
+ } catch(e){
+ var ret = iterator['return'];
+ if(ret !== undefined)anObject(ret.call(iterator));
+ throw e;
+ }
+};
+},{"./$.an-object":21}],44:[function(_dereq_,module,exports){
+'use strict';
+var $ = _dereq_('./$')
+ , descriptor = _dereq_('./$.property-desc')
+ , setToStringTag = _dereq_('./$.set-to-string-tag')
+ , IteratorPrototype = {};
+
+// 25.1.2.1.1 %IteratorPrototype%[@@iterator]()
+_dereq_('./$.hide')(IteratorPrototype, _dereq_('./$.wks')('iterator'), function(){ return this; });
+
+module.exports = function(Constructor, NAME, next){
+ Constructor.prototype = $.create(IteratorPrototype, {next: descriptor(1, next)});
+ setToStringTag(Constructor, NAME + ' Iterator');
+};
+},{"./$":49,"./$.hide":37,"./$.property-desc":54,"./$.set-to-string-tag":60,"./$.wks":71}],45:[function(_dereq_,module,exports){
+'use strict';
+var LIBRARY = _dereq_('./$.library')
+ , $export = _dereq_('./$.export')
+ , redefine = _dereq_('./$.redefine')
+ , hide = _dereq_('./$.hide')
+ , has = _dereq_('./$.has')
+ , Iterators = _dereq_('./$.iterators')
+ , $iterCreate = _dereq_('./$.iter-create')
+ , setToStringTag = _dereq_('./$.set-to-string-tag')
+ , getProto = _dereq_('./$').getProto
+ , ITERATOR = _dereq_('./$.wks')('iterator')
+ , BUGGY = !([].keys && 'next' in [].keys()) // Safari has buggy iterators w/o `next`
+ , FF_ITERATOR = '@@iterator'
+ , KEYS = 'keys'
+ , VALUES = 'values';
+
+var returnThis = function(){ return this; };
+
+module.exports = function(Base, NAME, Constructor, next, DEFAULT, IS_SET, FORCED){
+ $iterCreate(Constructor, NAME, next);
+ var getMethod = function(kind){
+ if(!BUGGY && kind in proto)return proto[kind];
+ switch(kind){
+ case KEYS: return function keys(){ return new Constructor(this, kind); };
+ case VALUES: return function values(){ return new Constructor(this, kind); };
+ } return function entries(){ return new Constructor(this, kind); };
+ };
+ var TAG = NAME + ' Iterator'
+ , DEF_VALUES = DEFAULT == VALUES
+ , VALUES_BUG = false
+ , proto = Base.prototype
+ , $native = proto[ITERATOR] || proto[FF_ITERATOR] || DEFAULT && proto[DEFAULT]
+ , $default = $native || getMethod(DEFAULT)
+ , methods, key;
+ // Fix native
+ if($native){
+ var IteratorPrototype = getProto($default.call(new Base));
+ // Set @@toStringTag to native iterators
+ setToStringTag(IteratorPrototype, TAG, true);
+ // FF fix
+ if(!LIBRARY && has(proto, FF_ITERATOR))hide(IteratorPrototype, ITERATOR, returnThis);
+ // fix Array#{values, @@iterator}.name in V8 / FF
+ if(DEF_VALUES && $native.name !== VALUES){
+ VALUES_BUG = true;
+ $default = function values(){ return $native.call(this); };
+ }
+ }
+ // Define iterator
+ if((!LIBRARY || FORCED) && (BUGGY || VALUES_BUG || !proto[ITERATOR])){
+ hide(proto, ITERATOR, $default);
+ }
+ // Plug for library
+ Iterators[NAME] = $default;
+ Iterators[TAG] = returnThis;
+ if(DEFAULT){
+ methods = {
+ values: DEF_VALUES ? $default : getMethod(VALUES),
+ keys: IS_SET ? $default : getMethod(KEYS),
+ entries: !DEF_VALUES ? $default : getMethod('entries')
+ };
+ if(FORCED)for(key in methods){
+ if(!(key in proto))redefine(proto, key, methods[key]);
+ } else $export($export.P + $export.F * (BUGGY || VALUES_BUG), NAME, methods);
+ }
+ return methods;
+};
+},{"./$":49,"./$.export":32,"./$.has":36,"./$.hide":37,"./$.iter-create":44,"./$.iterators":48,"./$.library":50,"./$.redefine":56,"./$.set-to-string-tag":60,"./$.wks":71}],46:[function(_dereq_,module,exports){
+var ITERATOR = _dereq_('./$.wks')('iterator')
+ , SAFE_CLOSING = false;
+
+try {
+ var riter = [7][ITERATOR]();
+ riter['return'] = function(){ SAFE_CLOSING = true; };
+ Array.from(riter, function(){ throw 2; });
+} catch(e){ /* empty */ }
+
+module.exports = function(exec, skipClosing){
+ if(!skipClosing && !SAFE_CLOSING)return false;
+ var safe = false;
+ try {
+ var arr = [7]
+ , iter = arr[ITERATOR]();
+ iter.next = function(){ safe = true; };
+ arr[ITERATOR] = function(){ return iter; };
+ exec(arr);
+ } catch(e){ /* empty */ }
+ return safe;
+};
+},{"./$.wks":71}],47:[function(_dereq_,module,exports){
+module.exports = function(done, value){
+ return {value: value, done: !!done};
+};
+},{}],48:[function(_dereq_,module,exports){
+module.exports = {};
+},{}],49:[function(_dereq_,module,exports){
+var $Object = Object;
+module.exports = {
+ create: $Object.create,
+ getProto: $Object.getPrototypeOf,
+ isEnum: {}.propertyIsEnumerable,
+ getDesc: $Object.getOwnPropertyDescriptor,
+ setDesc: $Object.defineProperty,
+ setDescs: $Object.defineProperties,
+ getKeys: $Object.keys,
+ getNames: $Object.getOwnPropertyNames,
+ getSymbols: $Object.getOwnPropertySymbols,
+ each: [].forEach
+};
+},{}],50:[function(_dereq_,module,exports){
+module.exports = true;
+},{}],51:[function(_dereq_,module,exports){
+var global = _dereq_('./$.global')
+ , macrotask = _dereq_('./$.task').set
+ , Observer = global.MutationObserver || global.WebKitMutationObserver
+ , process = global.process
+ , Promise = global.Promise
+ , isNode = _dereq_('./$.cof')(process) == 'process'
+ , head, last, notify;
+
+var flush = function(){
+ var parent, domain, fn;
+ if(isNode && (parent = process.domain)){
+ process.domain = null;
+ parent.exit();
+ }
+ while(head){
+ domain = head.domain;
+ fn = head.fn;
+ if(domain)domain.enter();
+ fn(); // <- currently we use it only for Promise - try / catch not required
+ if(domain)domain.exit();
+ head = head.next;
+ } last = undefined;
+ if(parent)parent.enter();
+};
+
+// Node.js
+if(isNode){
+ notify = function(){
+ process.nextTick(flush);
+ };
+// browsers with MutationObserver
+} else if(Observer){
+ var toggle = 1
+ , node = document.createTextNode('');
+ new Observer(flush).observe(node, {characterData: true}); // eslint-disable-line no-new
+ notify = function(){
+ node.data = toggle = -toggle;
+ };
+// environments with maybe non-completely correct, but existent Promise
+} else if(Promise && Promise.resolve){
+ notify = function(){
+ Promise.resolve().then(flush);
+ };
+// for other environments - macrotask based on:
+// - setImmediate
+// - MessageChannel
+// - window.postMessag
+// - onreadystatechange
+// - setTimeout
+} else {
+ notify = function(){
+ // strange IE + webpack dev server bug - use .call(global)
+ macrotask.call(global, flush);
+ };
+}
+
+module.exports = function asap(fn){
+ var task = {fn: fn, next: undefined, domain: isNode && process.domain};
+ if(last)last.next = task;
+ if(!head){
+ head = task;
+ notify();
+ } last = task;
+};
+},{"./$.cof":23,"./$.global":35,"./$.task":65}],52:[function(_dereq_,module,exports){
+// 19.1.2.1 Object.assign(target, source, ...)
+var $ = _dereq_('./$')
+ , toObject = _dereq_('./$.to-object')
+ , IObject = _dereq_('./$.iobject');
+
+// should work with symbols and should have deterministic property order (V8 bug)
+module.exports = _dereq_('./$.fails')(function(){
+ var a = Object.assign
+ , A = {}
+ , B = {}
+ , S = Symbol()
+ , K = 'abcdefghijklmnopqrst';
+ A[S] = 7;
+ K.split('').forEach(function(k){ B[k] = k; });
+ return a({}, A)[S] != 7 || Object.keys(a({}, B)).join('') != K;
+}) ? function assign(target, source){ // eslint-disable-line no-unused-vars
+ var T = toObject(target)
+ , $$ = arguments
+ , $$len = $$.length
+ , index = 1
+ , getKeys = $.getKeys
+ , getSymbols = $.getSymbols
+ , isEnum = $.isEnum;
+ while($$len > index){
+ var S = IObject($$[index++])
+ , keys = getSymbols ? getKeys(S).concat(getSymbols(S)) : getKeys(S)
+ , length = keys.length
+ , j = 0
+ , key;
+ while(length > j)if(isEnum.call(S, key = keys[j++]))T[key] = S[key];
+ }
+ return T;
+} : Object.assign;
+},{"./$":49,"./$.fails":33,"./$.iobject":40,"./$.to-object":69}],53:[function(_dereq_,module,exports){
+// most Object methods by ES6 should accept primitives
+var $export = _dereq_('./$.export')
+ , core = _dereq_('./$.core')
+ , fails = _dereq_('./$.fails');
+module.exports = function(KEY, exec){
+ var fn = (core.Object || {})[KEY] || Object[KEY]
+ , exp = {};
+ exp[KEY] = exec(fn);
+ $export($export.S + $export.F * fails(function(){ fn(1); }), 'Object', exp);
+};
+},{"./$.core":27,"./$.export":32,"./$.fails":33}],54:[function(_dereq_,module,exports){
+module.exports = function(bitmap, value){
+ return {
+ enumerable : !(bitmap & 1),
+ configurable: !(bitmap & 2),
+ writable : !(bitmap & 4),
+ value : value
+ };
+};
+},{}],55:[function(_dereq_,module,exports){
+var redefine = _dereq_('./$.redefine');
+module.exports = function(target, src){
+ for(var key in src)redefine(target, key, src[key]);
+ return target;
+};
+},{"./$.redefine":56}],56:[function(_dereq_,module,exports){
+module.exports = _dereq_('./$.hide');
+},{"./$.hide":37}],57:[function(_dereq_,module,exports){
+// 7.2.9 SameValue(x, y)
+module.exports = Object.is || function is(x, y){
+ return x === y ? x !== 0 || 1 / x === 1 / y : x != x && y != y;
+};
+},{}],58:[function(_dereq_,module,exports){
+// Works with __proto__ only. Old v8 can't work with null proto objects.
+/* eslint-disable no-proto */
+var getDesc = _dereq_('./$').getDesc
+ , isObject = _dereq_('./$.is-object')
+ , anObject = _dereq_('./$.an-object');
+var check = function(O, proto){
+ anObject(O);
+ if(!isObject(proto) && proto !== null)throw TypeError(proto + ": can't set as prototype!");
+};
+module.exports = {
+ set: Object.setPrototypeOf || ('__proto__' in {} ? // eslint-disable-line
+ function(test, buggy, set){
+ try {
+ set = _dereq_('./$.ctx')(Function.call, getDesc(Object.prototype, '__proto__').set, 2);
+ set(test, []);
+ buggy = !(test instanceof Array);
+ } catch(e){ buggy = true; }
+ return function setPrototypeOf(O, proto){
+ check(O, proto);
+ if(buggy)O.__proto__ = proto;
+ else set(O, proto);
+ return O;
+ };
+ }({}, false) : undefined),
+ check: check
+};
+},{"./$":49,"./$.an-object":21,"./$.ctx":28,"./$.is-object":42}],59:[function(_dereq_,module,exports){
+'use strict';
+var core = _dereq_('./$.core')
+ , $ = _dereq_('./$')
+ , DESCRIPTORS = _dereq_('./$.descriptors')
+ , SPECIES = _dereq_('./$.wks')('species');
+
+module.exports = function(KEY){
+ var C = core[KEY];
+ if(DESCRIPTORS && C && !C[SPECIES])$.setDesc(C, SPECIES, {
+ configurable: true,
+ get: function(){ return this; }
+ });
+};
+},{"./$":49,"./$.core":27,"./$.descriptors":30,"./$.wks":71}],60:[function(_dereq_,module,exports){
+var def = _dereq_('./$').setDesc
+ , has = _dereq_('./$.has')
+ , TAG = _dereq_('./$.wks')('toStringTag');
+
+module.exports = function(it, tag, stat){
+ if(it && !has(it = stat ? it : it.prototype, TAG))def(it, TAG, {configurable: true, value: tag});
+};
+},{"./$":49,"./$.has":36,"./$.wks":71}],61:[function(_dereq_,module,exports){
+var global = _dereq_('./$.global')
+ , SHARED = '__core-js_shared__'
+ , store = global[SHARED] || (global[SHARED] = {});
+module.exports = function(key){
+ return store[key] || (store[key] = {});
+};
+},{"./$.global":35}],62:[function(_dereq_,module,exports){
+// 7.3.20 SpeciesConstructor(O, defaultConstructor)
+var anObject = _dereq_('./$.an-object')
+ , aFunction = _dereq_('./$.a-function')
+ , SPECIES = _dereq_('./$.wks')('species');
+module.exports = function(O, D){
+ var C = anObject(O).constructor, S;
+ return C === undefined || (S = anObject(C)[SPECIES]) == undefined ? D : aFunction(S);
+};
+},{"./$.a-function":19,"./$.an-object":21,"./$.wks":71}],63:[function(_dereq_,module,exports){
+module.exports = function(it, Constructor, name){
+ if(!(it instanceof Constructor))throw TypeError(name + ": use the 'new' operator!");
+ return it;
+};
+},{}],64:[function(_dereq_,module,exports){
+var toInteger = _dereq_('./$.to-integer')
+ , defined = _dereq_('./$.defined');
+// true -> String#at
+// false -> String#codePointAt
+module.exports = function(TO_STRING){
+ return function(that, pos){
+ var s = String(defined(that))
+ , i = toInteger(pos)
+ , l = s.length
+ , a, b;
+ if(i < 0 || i >= l)return TO_STRING ? '' : undefined;
+ a = s.charCodeAt(i);
+ return a < 0xd800 || a > 0xdbff || i + 1 === l || (b = s.charCodeAt(i + 1)) < 0xdc00 || b > 0xdfff
+ ? TO_STRING ? s.charAt(i) : a
+ : TO_STRING ? s.slice(i, i + 2) : (a - 0xd800 << 10) + (b - 0xdc00) + 0x10000;
+ };
+};
+},{"./$.defined":29,"./$.to-integer":66}],65:[function(_dereq_,module,exports){
+var ctx = _dereq_('./$.ctx')
+ , invoke = _dereq_('./$.invoke')
+ , html = _dereq_('./$.html')
+ , cel = _dereq_('./$.dom-create')
+ , global = _dereq_('./$.global')
+ , process = global.process
+ , setTask = global.setImmediate
+ , clearTask = global.clearImmediate
+ , MessageChannel = global.MessageChannel
+ , counter = 0
+ , queue = {}
+ , ONREADYSTATECHANGE = 'onreadystatechange'
+ , defer, channel, port;
+var run = function(){
+ var id = +this;
+ if(queue.hasOwnProperty(id)){
+ var fn = queue[id];
+ delete queue[id];
+ fn();
+ }
+};
+var listner = function(event){
+ run.call(event.data);
+};
+// Node.js 0.9+ & IE10+ has setImmediate, otherwise:
+if(!setTask || !clearTask){
+ setTask = function setImmediate(fn){
+ var args = [], i = 1;
+ while(arguments.length > i)args.push(arguments[i++]);
+ queue[++counter] = function(){
+ invoke(typeof fn == 'function' ? fn : Function(fn), args);
+ };
+ defer(counter);
+ return counter;
+ };
+ clearTask = function clearImmediate(id){
+ delete queue[id];
+ };
+ // Node.js 0.8-
+ if(_dereq_('./$.cof')(process) == 'process'){
+ defer = function(id){
+ process.nextTick(ctx(run, id, 1));
+ };
+ // Browsers with MessageChannel, includes WebWorkers
+ } else if(MessageChannel){
+ channel = new MessageChannel;
+ port = channel.port2;
+ channel.port1.onmessage = listner;
+ defer = ctx(port.postMessage, port, 1);
+ // Browsers with postMessage, skip WebWorkers
+ // IE8 has postMessage, but it's sync & typeof its postMessage is 'object'
+ } else if(global.addEventListener && typeof postMessage == 'function' && !global.importScripts){
+ defer = function(id){
+ global.postMessage(id + '', '*');
+ };
+ global.addEventListener('message', listner, false);
+ // IE8-
+ } else if(ONREADYSTATECHANGE in cel('script')){
+ defer = function(id){
+ html.appendChild(cel('script'))[ONREADYSTATECHANGE] = function(){
+ html.removeChild(this);
+ run.call(id);
+ };
+ };
+ // Rest old browsers
+ } else {
+ defer = function(id){
+ setTimeout(ctx(run, id, 1), 0);
+ };
+ }
+}
+module.exports = {
+ set: setTask,
+ clear: clearTask
+};
+},{"./$.cof":23,"./$.ctx":28,"./$.dom-create":31,"./$.global":35,"./$.html":38,"./$.invoke":39}],66:[function(_dereq_,module,exports){
+// 7.1.4 ToInteger
+var ceil = Math.ceil
+ , floor = Math.floor;
+module.exports = function(it){
+ return isNaN(it = +it) ? 0 : (it > 0 ? floor : ceil)(it);
+};
+},{}],67:[function(_dereq_,module,exports){
+// to indexed object, toObject with fallback for non-array-like ES3 strings
+var IObject = _dereq_('./$.iobject')
+ , defined = _dereq_('./$.defined');
+module.exports = function(it){
+ return IObject(defined(it));
+};
+},{"./$.defined":29,"./$.iobject":40}],68:[function(_dereq_,module,exports){
+// 7.1.15 ToLength
+var toInteger = _dereq_('./$.to-integer')
+ , min = Math.min;
+module.exports = function(it){
+ return it > 0 ? min(toInteger(it), 0x1fffffffffffff) : 0; // pow(2, 53) - 1 == 9007199254740991
+};
+},{"./$.to-integer":66}],69:[function(_dereq_,module,exports){
+// 7.1.13 ToObject(argument)
+var defined = _dereq_('./$.defined');
+module.exports = function(it){
+ return Object(defined(it));
+};
+},{"./$.defined":29}],70:[function(_dereq_,module,exports){
+var id = 0
+ , px = Math.random();
+module.exports = function(key){
+ return 'Symbol('.concat(key === undefined ? '' : key, ')_', (++id + px).toString(36));
+};
+},{}],71:[function(_dereq_,module,exports){
+var store = _dereq_('./$.shared')('wks')
+ , uid = _dereq_('./$.uid')
+ , Symbol = _dereq_('./$.global').Symbol;
+module.exports = function(name){
+ return store[name] || (store[name] =
+ Symbol && Symbol[name] || (Symbol || uid)('Symbol.' + name));
+};
+},{"./$.global":35,"./$.shared":61,"./$.uid":70}],72:[function(_dereq_,module,exports){
+var classof = _dereq_('./$.classof')
+ , ITERATOR = _dereq_('./$.wks')('iterator')
+ , Iterators = _dereq_('./$.iterators');
+module.exports = _dereq_('./$.core').getIteratorMethod = function(it){
+ if(it != undefined)return it[ITERATOR]
+ || it['@@iterator']
+ || Iterators[classof(it)];
+};
+},{"./$.classof":22,"./$.core":27,"./$.iterators":48,"./$.wks":71}],73:[function(_dereq_,module,exports){
+var anObject = _dereq_('./$.an-object')
+ , get = _dereq_('./core.get-iterator-method');
+module.exports = _dereq_('./$.core').getIterator = function(it){
+ var iterFn = get(it);
+ if(typeof iterFn != 'function')throw TypeError(it + ' is not iterable!');
+ return anObject(iterFn.call(it));
+};
+},{"./$.an-object":21,"./$.core":27,"./core.get-iterator-method":72}],74:[function(_dereq_,module,exports){
+'use strict';
+var ctx = _dereq_('./$.ctx')
+ , $export = _dereq_('./$.export')
+ , toObject = _dereq_('./$.to-object')
+ , call = _dereq_('./$.iter-call')
+ , isArrayIter = _dereq_('./$.is-array-iter')
+ , toLength = _dereq_('./$.to-length')
+ , getIterFn = _dereq_('./core.get-iterator-method');
+$export($export.S + $export.F * !_dereq_('./$.iter-detect')(function(iter){ Array.from(iter); }), 'Array', {
+ // 22.1.2.1 Array.from(arrayLike, mapfn = undefined, thisArg = undefined)
+ from: function from(arrayLike/*, mapfn = undefined, thisArg = undefined*/){
+ var O = toObject(arrayLike)
+ , C = typeof this == 'function' ? this : Array
+ , $$ = arguments
+ , $$len = $$.length
+ , mapfn = $$len > 1 ? $$[1] : undefined
+ , mapping = mapfn !== undefined
+ , index = 0
+ , iterFn = getIterFn(O)
+ , length, result, step, iterator;
+ if(mapping)mapfn = ctx(mapfn, $$len > 2 ? $$[2] : undefined, 2);
+ // if object isn't iterable or it's array with default iterator - use simple case
+ if(iterFn != undefined && !(C == Array && isArrayIter(iterFn))){
+ for(iterator = iterFn.call(O), result = new C; !(step = iterator.next()).done; index++){
+ result[index] = mapping ? call(iterator, mapfn, [step.value, index], true) : step.value;
+ }
+ } else {
+ length = toLength(O.length);
+ for(result = new C(length); length > index; index++){
+ result[index] = mapping ? mapfn(O[index], index) : O[index];
+ }
+ }
+ result.length = index;
+ return result;
+ }
+});
+
+},{"./$.ctx":28,"./$.export":32,"./$.is-array-iter":41,"./$.iter-call":43,"./$.iter-detect":46,"./$.to-length":68,"./$.to-object":69,"./core.get-iterator-method":72}],75:[function(_dereq_,module,exports){
+'use strict';
+var addToUnscopables = _dereq_('./$.add-to-unscopables')
+ , step = _dereq_('./$.iter-step')
+ , Iterators = _dereq_('./$.iterators')
+ , toIObject = _dereq_('./$.to-iobject');
+
+// 22.1.3.4 Array.prototype.entries()
+// 22.1.3.13 Array.prototype.keys()
+// 22.1.3.29 Array.prototype.values()
+// 22.1.3.30 Array.prototype[@@iterator]()
+module.exports = _dereq_('./$.iter-define')(Array, 'Array', function(iterated, kind){
+ this._t = toIObject(iterated); // target
+ this._i = 0; // next index
+ this._k = kind; // kind
+// 22.1.5.2.1 %ArrayIteratorPrototype%.next()
+}, function(){
+ var O = this._t
+ , kind = this._k
+ , index = this._i++;
+ if(!O || index >= O.length){
+ this._t = undefined;
+ return step(1);
+ }
+ if(kind == 'keys' )return step(0, index);
+ if(kind == 'values')return step(0, O[index]);
+ return step(0, [index, O[index]]);
+}, 'values');
+
+// argumentsList[@@iterator] is %ArrayProto_values% (9.4.4.6, 9.4.4.7)
+Iterators.Arguments = Iterators.Array;
+
+addToUnscopables('keys');
+addToUnscopables('values');
+addToUnscopables('entries');
+},{"./$.add-to-unscopables":20,"./$.iter-define":45,"./$.iter-step":47,"./$.iterators":48,"./$.to-iobject":67}],76:[function(_dereq_,module,exports){
+// 19.1.3.1 Object.assign(target, source)
+var $export = _dereq_('./$.export');
+
+$export($export.S + $export.F, 'Object', {assign: _dereq_('./$.object-assign')});
+},{"./$.export":32,"./$.object-assign":52}],77:[function(_dereq_,module,exports){
+// 19.1.2.14 Object.keys(O)
+var toObject = _dereq_('./$.to-object');
+
+_dereq_('./$.object-sap')('keys', function($keys){
+ return function keys(it){
+ return $keys(toObject(it));
+ };
+});
+},{"./$.object-sap":53,"./$.to-object":69}],78:[function(_dereq_,module,exports){
+
+},{}],79:[function(_dereq_,module,exports){
+'use strict';
+var $ = _dereq_('./$')
+ , LIBRARY = _dereq_('./$.library')
+ , global = _dereq_('./$.global')
+ , ctx = _dereq_('./$.ctx')
+ , classof = _dereq_('./$.classof')
+ , $export = _dereq_('./$.export')
+ , isObject = _dereq_('./$.is-object')
+ , anObject = _dereq_('./$.an-object')
+ , aFunction = _dereq_('./$.a-function')
+ , strictNew = _dereq_('./$.strict-new')
+ , forOf = _dereq_('./$.for-of')
+ , setProto = _dereq_('./$.set-proto').set
+ , same = _dereq_('./$.same-value')
+ , SPECIES = _dereq_('./$.wks')('species')
+ , speciesConstructor = _dereq_('./$.species-constructor')
+ , asap = _dereq_('./$.microtask')
+ , PROMISE = 'Promise'
+ , process = global.process
+ , isNode = classof(process) == 'process'
+ , P = global[PROMISE]
+ , Wrapper;
+
+var testResolve = function(sub){
+ var test = new P(function(){});
+ if(sub)test.constructor = Object;
+ return P.resolve(test) === test;
+};
+
+var USE_NATIVE = function(){
+ var works = false;
+ function P2(x){
+ var self = new P(x);
+ setProto(self, P2.prototype);
+ return self;
+ }
+ try {
+ works = P && P.resolve && testResolve();
+ setProto(P2, P);
+ P2.prototype = $.create(P.prototype, {constructor: {value: P2}});
+ // actual Firefox has broken subclass support, test that
+ if(!(P2.resolve(5).then(function(){}) instanceof P2)){
+ works = false;
+ }
+ // actual V8 bug, https://code.google.com/p/v8/issues/detail?id=4162
+ if(works && _dereq_('./$.descriptors')){
+ var thenableThenGotten = false;
+ P.resolve($.setDesc({}, 'then', {
+ get: function(){ thenableThenGotten = true; }
+ }));
+ works = thenableThenGotten;
+ }
+ } catch(e){ works = false; }
+ return works;
+}();
+
+// helpers
+var sameConstructor = function(a, b){
+ // library wrapper special case
+ if(LIBRARY && a === P && b === Wrapper)return true;
+ return same(a, b);
+};
+var getConstructor = function(C){
+ var S = anObject(C)[SPECIES];
+ return S != undefined ? S : C;
+};
+var isThenable = function(it){
+ var then;
+ return isObject(it) && typeof (then = it.then) == 'function' ? then : false;
+};
+var PromiseCapability = function(C){
+ var resolve, reject;
+ this.promise = new C(function($$resolve, $$reject){
+ if(resolve !== undefined || reject !== undefined)throw TypeError('Bad Promise constructor');
+ resolve = $$resolve;
+ reject = $$reject;
+ });
+ this.resolve = aFunction(resolve),
+ this.reject = aFunction(reject)
+};
+var perform = function(exec){
+ try {
+ exec();
+ } catch(e){
+ return {error: e};
+ }
+};
+var notify = function(record, isReject){
+ if(record.n)return;
+ record.n = true;
+ var chain = record.c;
+ asap(function(){
+ var value = record.v
+ , ok = record.s == 1
+ , i = 0;
+ var run = function(reaction){
+ var handler = ok ? reaction.ok : reaction.fail
+ , resolve = reaction.resolve
+ , reject = reaction.reject
+ , result, then;
+ try {
+ if(handler){
+ if(!ok)record.h = true;
+ result = handler === true ? value : handler(value);
+ if(result === reaction.promise){
+ reject(TypeError('Promise-chain cycle'));
+ } else if(then = isThenable(result)){
+ then.call(result, resolve, reject);
+ } else resolve(result);
+ } else reject(value);
+ } catch(e){
+ reject(e);
+ }
+ };
+ while(chain.length > i)run(chain[i++]); // variable length - can't use forEach
+ chain.length = 0;
+ record.n = false;
+ if(isReject)setTimeout(function(){
+ var promise = record.p
+ , handler, console;
+ if(isUnhandled(promise)){
+ if(isNode){
+ process.emit('unhandledRejection', value, promise);
+ } else if(handler = global.onunhandledrejection){
+ handler({promise: promise, reason: value});
+ } else if((console = global.console) && console.error){
+ console.error('Unhandled promise rejection', value);
+ }
+ } record.a = undefined;
+ }, 1);
+ });
+};
+var isUnhandled = function(promise){
+ var record = promise._d
+ , chain = record.a || record.c
+ , i = 0
+ , reaction;
+ if(record.h)return false;
+ while(chain.length > i){
+ reaction = chain[i++];
+ if(reaction.fail || !isUnhandled(reaction.promise))return false;
+ } return true;
+};
+var $reject = function(value){
+ var record = this;
+ if(record.d)return;
+ record.d = true;
+ record = record.r || record; // unwrap
+ record.v = value;
+ record.s = 2;
+ record.a = record.c.slice();
+ notify(record, true);
+};
+var $resolve = function(value){
+ var record = this
+ , then;
+ if(record.d)return;
+ record.d = true;
+ record = record.r || record; // unwrap
+ try {
+ if(record.p === value)throw TypeError("Promise can't be resolved itself");
+ if(then = isThenable(value)){
+ asap(function(){
+ var wrapper = {r: record, d: false}; // wrap
+ try {
+ then.call(value, ctx($resolve, wrapper, 1), ctx($reject, wrapper, 1));
+ } catch(e){
+ $reject.call(wrapper, e);
+ }
+ });
+ } else {
+ record.v = value;
+ record.s = 1;
+ notify(record, false);
+ }
+ } catch(e){
+ $reject.call({r: record, d: false}, e); // wrap
+ }
+};
+
+// constructor polyfill
+if(!USE_NATIVE){
+ // 25.4.3.1 Promise(executor)
+ P = function Promise(executor){
+ aFunction(executor);
+ var record = this._d = {
+ p: strictNew(this, P, PROMISE), // <- promise
+ c: [], // <- awaiting reactions
+ a: undefined, // <- checked in isUnhandled reactions
+ s: 0, // <- state
+ d: false, // <- done
+ v: undefined, // <- value
+ h: false, // <- handled rejection
+ n: false // <- notify
+ };
+ try {
+ executor(ctx($resolve, record, 1), ctx($reject, record, 1));
+ } catch(err){
+ $reject.call(record, err);
+ }
+ };
+ _dereq_('./$.redefine-all')(P.prototype, {
+ // 25.4.5.3 Promise.prototype.then(onFulfilled, onRejected)
+ then: function then(onFulfilled, onRejected){
+ var reaction = new PromiseCapability(speciesConstructor(this, P))
+ , promise = reaction.promise
+ , record = this._d;
+ reaction.ok = typeof onFulfilled == 'function' ? onFulfilled : true;
+ reaction.fail = typeof onRejected == 'function' && onRejected;
+ record.c.push(reaction);
+ if(record.a)record.a.push(reaction);
+ if(record.s)notify(record, false);
+ return promise;
+ },
+ // 25.4.5.1 Promise.prototype.catch(onRejected)
+ 'catch': function(onRejected){
+ return this.then(undefined, onRejected);
+ }
+ });
+}
+
+$export($export.G + $export.W + $export.F * !USE_NATIVE, {Promise: P});
+_dereq_('./$.set-to-string-tag')(P, PROMISE);
+_dereq_('./$.set-species')(PROMISE);
+Wrapper = _dereq_('./$.core')[PROMISE];
+
+// statics
+$export($export.S + $export.F * !USE_NATIVE, PROMISE, {
+ // 25.4.4.5 Promise.reject(r)
+ reject: function reject(r){
+ var capability = new PromiseCapability(this)
+ , $$reject = capability.reject;
+ $$reject(r);
+ return capability.promise;
+ }
+});
+$export($export.S + $export.F * (!USE_NATIVE || testResolve(true)), PROMISE, {
+ // 25.4.4.6 Promise.resolve(x)
+ resolve: function resolve(x){
+ // instanceof instead of internal slot check because we should fix it without replacement native Promise core
+ if(x instanceof P && sameConstructor(x.constructor, this))return x;
+ var capability = new PromiseCapability(this)
+ , $$resolve = capability.resolve;
+ $$resolve(x);
+ return capability.promise;
+ }
+});
+$export($export.S + $export.F * !(USE_NATIVE && _dereq_('./$.iter-detect')(function(iter){
+ P.all(iter)['catch'](function(){});
+})), PROMISE, {
+ // 25.4.4.1 Promise.all(iterable)
+ all: function all(iterable){
+ var C = getConstructor(this)
+ , capability = new PromiseCapability(C)
+ , resolve = capability.resolve
+ , reject = capability.reject
+ , values = [];
+ var abrupt = perform(function(){
+ forOf(iterable, false, values.push, values);
+ var remaining = values.length
+ , results = Array(remaining);
+ if(remaining)$.each.call(values, function(promise, index){
+ var alreadyCalled = false;
+ C.resolve(promise).then(function(value){
+ if(alreadyCalled)return;
+ alreadyCalled = true;
+ results[index] = value;
+ --remaining || resolve(results);
+ }, reject);
+ });
+ else resolve(results);
+ });
+ if(abrupt)reject(abrupt.error);
+ return capability.promise;
+ },
+ // 25.4.4.4 Promise.race(iterable)
+ race: function race(iterable){
+ var C = getConstructor(this)
+ , capability = new PromiseCapability(C)
+ , reject = capability.reject;
+ var abrupt = perform(function(){
+ forOf(iterable, false, function(promise){
+ C.resolve(promise).then(capability.resolve, reject);
+ });
+ });
+ if(abrupt)reject(abrupt.error);
+ return capability.promise;
+ }
+});
+},{"./$":49,"./$.a-function":19,"./$.an-object":21,"./$.classof":22,"./$.core":27,"./$.ctx":28,"./$.descriptors":30,"./$.export":32,"./$.for-of":34,"./$.global":35,"./$.is-object":42,"./$.iter-detect":46,"./$.library":50,"./$.microtask":51,"./$.redefine-all":55,"./$.same-value":57,"./$.set-proto":58,"./$.set-species":59,"./$.set-to-string-tag":60,"./$.species-constructor":62,"./$.strict-new":63,"./$.wks":71}],80:[function(_dereq_,module,exports){
+'use strict';
+var strong = _dereq_('./$.collection-strong');
+
+// 23.2 Set Objects
+_dereq_('./$.collection')('Set', function(get){
+ return function Set(){ return get(this, arguments.length > 0 ? arguments[0] : undefined); };
+}, {
+ // 23.2.3.1 Set.prototype.add(value)
+ add: function add(value){
+ return strong.def(this, value = value === 0 ? 0 : value, value);
+ }
+}, strong);
+},{"./$.collection":26,"./$.collection-strong":24}],81:[function(_dereq_,module,exports){
+'use strict';
+var $at = _dereq_('./$.string-at')(true);
+
+// 21.1.3.27 String.prototype[@@iterator]()
+_dereq_('./$.iter-define')(String, 'String', function(iterated){
+ this._t = String(iterated); // target
+ this._i = 0; // next index
+// 21.1.5.2.1 %StringIteratorPrototype%.next()
+}, function(){
+ var O = this._t
+ , index = this._i
+ , point;
+ if(index >= O.length)return {value: undefined, done: true};
+ point = $at(O, index);
+ this._i += point.length;
+ return {value: point, done: false};
+});
+},{"./$.iter-define":45,"./$.string-at":64}],82:[function(_dereq_,module,exports){
+// https://github.com/DavidBruant/Map-Set.prototype.toJSON
+var $export = _dereq_('./$.export');
+
+$export($export.P, 'Set', {toJSON: _dereq_('./$.collection-to-json')('Set')});
+},{"./$.collection-to-json":25,"./$.export":32}],83:[function(_dereq_,module,exports){
+_dereq_('./es6.array.iterator');
+var Iterators = _dereq_('./$.iterators');
+Iterators.NodeList = Iterators.HTMLCollection = Iterators.Array;
+},{"./$.iterators":48,"./es6.array.iterator":75}],84:[function(_dereq_,module,exports){
+var isFunction = _dereq_('is-function')
+
+module.exports = forEach
+
+var toString = Object.prototype.toString
+var hasOwnProperty = Object.prototype.hasOwnProperty
+
+function forEach(list, iterator, context) {
+ if (!isFunction(iterator)) {
+ throw new TypeError('iterator must be a function')
+ }
+
+ if (arguments.length < 3) {
+ context = this
+ }
+
+ if (toString.call(list) === '[object Array]')
+ forEachArray(list, iterator, context)
+ else if (typeof list === 'string')
+ forEachString(list, iterator, context)
+ else
+ forEachObject(list, iterator, context)
+}
+
+function forEachArray(array, iterator, context) {
+ for (var i = 0, len = array.length; i < len; i++) {
+ if (hasOwnProperty.call(array, i)) {
+ iterator.call(context, array[i], i, array)
+ }
+ }
+}
+
+function forEachString(string, iterator, context) {
+ for (var i = 0, len = string.length; i < len; i++) {
+ // no such thing as a sparse string.
+ iterator.call(context, string.charAt(i), i, string)
+ }
+}
+
+function forEachObject(object, iterator, context) {
+ for (var k in object) {
+ if (hasOwnProperty.call(object, k)) {
+ iterator.call(context, object[k], k, object)
+ }
+ }
+}
+
+},{"is-function":86}],85:[function(_dereq_,module,exports){
+(function (global){
+if (typeof window !== "undefined") {
+ module.exports = window;
+} else if (typeof global !== "undefined") {
+ module.exports = global;
+} else if (typeof self !== "undefined"){
+ module.exports = self;
+} else {
+ module.exports = {};
+}
+
+}).call(this,typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {})
+
+},{}],86:[function(_dereq_,module,exports){
+module.exports = isFunction
+
+var toString = Object.prototype.toString
+
+function isFunction (fn) {
+ var string = toString.call(fn)
+ return string === '[object Function]' ||
+ (typeof fn === 'function' && string !== '[object RegExp]') ||
+ (typeof window !== 'undefined' &&
+ // IE8 and below
+ (fn === window.setTimeout ||
+ fn === window.alert ||
+ fn === window.confirm ||
+ fn === window.prompt))
+};
+
+},{}],87:[function(_dereq_,module,exports){
+var trim = _dereq_('trim')
+ , forEach = _dereq_('for-each')
+ , isArray = function(arg) {
+ return Object.prototype.toString.call(arg) === '[object Array]';
+ }
+
+module.exports = function (headers) {
+ if (!headers)
+ return {}
+
+ var result = {}
+
+ forEach(
+ trim(headers).split('\n')
+ , function (row) {
+ var index = row.indexOf(':')
+ , key = trim(row.slice(0, index)).toLowerCase()
+ , value = trim(row.slice(index + 1))
+
+ if (typeof(result[key]) === 'undefined') {
+ result[key] = value
+ } else if (isArray(result[key])) {
+ result[key].push(value)
+ } else {
+ result[key] = [ result[key], value ]
+ }
+ }
+ )
+
+ return result
+}
+},{"for-each":84,"trim":88}],88:[function(_dereq_,module,exports){
+
+exports = module.exports = trim;
+
+function trim(str){
+ return str.replace(/^\s*|\s*$/g, '');
+}
+
+exports.left = function(str){
+ return str.replace(/^\s*/, '');
+};
+
+exports.right = function(str){
+ return str.replace(/\s*$/, '');
+};
+
+},{}],89:[function(_dereq_,module,exports){
+"use strict";
+var window = _dereq_("global/window")
+var once = _dereq_("once")
+var isFunction = _dereq_("is-function")
+var parseHeaders = _dereq_("parse-headers")
+var xtend = _dereq_("xtend")
+
+module.exports = createXHR
+createXHR.XMLHttpRequest = window.XMLHttpRequest || noop
+createXHR.XDomainRequest = "withCredentials" in (new createXHR.XMLHttpRequest()) ? createXHR.XMLHttpRequest : window.XDomainRequest
+
+forEachArray(["get", "put", "post", "patch", "head", "delete"], function(method) {
+ createXHR[method === "delete" ? "del" : method] = function(uri, options, callback) {
+ options = initParams(uri, options, callback)
+ options.method = method.toUpperCase()
+ return _createXHR(options)
+ }
+})
+
+function forEachArray(array, iterator) {
+ for (var i = 0; i < array.length; i++) {
+ iterator(array[i])
+ }
+}
+
+function isEmpty(obj){
+ for(var i in obj){
+ if(obj.hasOwnProperty(i)) return false
+ }
+ return true
+}
+
+function initParams(uri, options, callback) {
+ var params = uri
+
+ if (isFunction(options)) {
+ callback = options
+ if (typeof uri === "string") {
+ params = {uri:uri}
+ }
+ } else {
+ params = xtend(options, {uri: uri})
+ }
+
+ params.callback = callback
+ return params
+}
+
+function createXHR(uri, options, callback) {
+ options = initParams(uri, options, callback)
+ return _createXHR(options)
+}
+
+function _createXHR(options) {
+ var callback = options.callback
+ if(typeof callback === "undefined"){
+ throw new Error("callback argument missing")
+ }
+ callback = once(callback)
+
+ function readystatechange() {
+ if (xhr.readyState === 4) {
+ loadFunc()
+ }
+ }
+
+ function getBody() {
+ // Chrome with requestType=blob throws errors arround when even testing access to responseText
+ var body = undefined
+
+ if (xhr.response) {
+ body = xhr.response
+ } else if (xhr.responseType === "text" || !xhr.responseType) {
+ body = xhr.responseText || xhr.responseXML
+ }
+
+ if (isJson) {
+ try {
+ body = JSON.parse(body)
+ } catch (e) {}
+ }
+
+ return body
+ }
+
+ var failureResponse = {
+ body: undefined,
+ headers: {},
+ statusCode: 0,
+ method: method,
+ url: uri,
+ rawRequest: xhr
+ }
+
+ function errorFunc(evt) {
+ clearTimeout(timeoutTimer)
+ if(!(evt instanceof Error)){
+ evt = new Error("" + (evt || "Unknown XMLHttpRequest Error") )
+ }
+ evt.statusCode = 0
+ callback(evt, failureResponse)
+ }
+
+ // will load the data & process the response in a special response object
+ function loadFunc() {
+ if (aborted) return
+ var status
+ clearTimeout(timeoutTimer)
+ if(options.useXDR && xhr.status===undefined) {
+ //IE8 CORS GET successful response doesn't have a status field, but body is fine
+ status = 200
+ } else {
+ status = (xhr.status === 1223 ? 204 : xhr.status)
+ }
+ var response = failureResponse
+ var err = null
+
+ if (status !== 0){
+ response = {
+ body: getBody(),
+ statusCode: status,
+ method: method,
+ headers: {},
+ url: uri,
+ rawRequest: xhr
+ }
+ if(xhr.getAllResponseHeaders){ //remember xhr can in fact be XDR for CORS in IE
+ response.headers = parseHeaders(xhr.getAllResponseHeaders())
+ }
+ } else {
+ err = new Error("Internal XMLHttpRequest Error")
+ }
+ callback(err, response, response.body)
+
+ }
+
+ var xhr = options.xhr || null
+
+ if (!xhr) {
+ if (options.cors || options.useXDR) {
+ xhr = new createXHR.XDomainRequest()
+ }else{
+ xhr = new createXHR.XMLHttpRequest()
+ }
+ }
+
+ var key
+ var aborted
+ var uri = xhr.url = options.uri || options.url
+ var method = xhr.method = options.method || "GET"
+ var body = options.body || options.data || null
+ var headers = xhr.headers = options.headers || {}
+ var sync = !!options.sync
+ var isJson = false
+ var timeoutTimer
+
+ if ("json" in options) {
+ isJson = true
+ headers["accept"] || headers["Accept"] || (headers["Accept"] = "application/json") //Don't override existing accept header declared by user
+ if (method !== "GET" && method !== "HEAD") {
+ headers["content-type"] || headers["Content-Type"] || (headers["Content-Type"] = "application/json") //Don't override existing accept header declared by user
+ body = JSON.stringify(options.json)
+ }
+ }
+
+ xhr.onreadystatechange = readystatechange
+ xhr.onload = loadFunc
+ xhr.onerror = errorFunc
+ // IE9 must have onprogress be set to a unique function.
+ xhr.onprogress = function () {
+ // IE must die
+ }
+ xhr.ontimeout = errorFunc
+ xhr.open(method, uri, !sync, options.username, options.password)
+ //has to be after open
+ if(!sync) {
+ xhr.withCredentials = !!options.withCredentials
+ }
+ // Cannot set timeout with sync request
+ // not setting timeout on the xhr object, because of old webkits etc. not handling that correctly
+ // both npm's request and jquery 1.x use this kind of timeout, so this is being consistent
+ if (!sync && options.timeout > 0 ) {
+ timeoutTimer = setTimeout(function(){
+ aborted=true//IE9 may still call readystatechange
+ xhr.abort("timeout")
+ var e = new Error("XMLHttpRequest timeout")
+ e.code = "ETIMEDOUT"
+ errorFunc(e)
+ }, options.timeout )
+ }
+
+ if (xhr.setRequestHeader) {
+ for(key in headers){
+ if(headers.hasOwnProperty(key)){
+ xhr.setRequestHeader(key, headers[key])
+ }
+ }
+ } else if (options.headers && !isEmpty(options.headers)) {
+ throw new Error("Headers cannot be set on an XDomainRequest object")
+ }
+
+ if ("responseType" in options) {
+ xhr.responseType = options.responseType
+ }
+
+ if ("beforeSend" in options &&
+ typeof options.beforeSend === "function"
+ ) {
+ options.beforeSend(xhr)
+ }
+
+ xhr.send(body)
+
+ return xhr
+
+
+}
+
+function noop() {}
+
+},{"global/window":85,"is-function":86,"once":90,"parse-headers":87,"xtend":91}],90:[function(_dereq_,module,exports){
+module.exports = once
+
+once.proto = once(function () {
+ Object.defineProperty(Function.prototype, 'once', {
+ value: function () {
+ return once(this)
+ },
+ configurable: true
+ })
+})
+
+function once (fn) {
+ var called = false
+ return function () {
+ if (called) return
+ called = true
+ return fn.apply(this, arguments)
+ }
+}
+
+},{}],91:[function(_dereq_,module,exports){
+module.exports = extend
+
+var hasOwnProperty = Object.prototype.hasOwnProperty;
+
+function extend() {
+ var target = {}
+
+ for (var i = 0; i < arguments.length; i++) {
+ var source = arguments[i]
+
+ for (var key in source) {
+ if (hasOwnProperty.call(source, key)) {
+ target[key] = source[key]
+ }
+ }
+ }
+
+ return target
+}
+
+},{}],92:[function(_dereq_,module,exports){
+/*
+The MIT License (MIT)
+
+Copyright (c) 2015 Patricio Gonzalez Vivo ( http://www.patriciogonzalezvivo.com )
+
+Permission is hereby granted, free of charge, to any person obtaining a copy of
+this software and associated documentation files (the 'Software'), to deal in
+the Software without restriction, including without limitation the rights to
+use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
+the Software, and to permit persons to whom the Software is furnished to do so,
+subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
+FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
+COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
+IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
+CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+*/
+
+'use strict';
+
+var _createClass = _dereq_('babel-runtime/helpers/create-class')['default'];
+
+var _classCallCheck = _dereq_('babel-runtime/helpers/class-call-check')['default'];
+
+var _interopRequireDefault = _dereq_('babel-runtime/helpers/interop-require-default')['default'];
+
+Object.defineProperty(exports, '__esModule', {
+ value: true
+});
+
+var _xhr = _dereq_('xhr');
+
+var _xhr2 = _interopRequireDefault(_xhr);
+
+var _glGl = _dereq_('./gl/gl');
+
+var _glTexture = _dereq_('./gl/Texture');
+
+var _glTexture2 = _interopRequireDefault(_glTexture);
+
+var _toolsCommon = _dereq_('./tools/common');
+
+var _toolsMixin = _dereq_('./tools/mixin');
+
+var GlslCanvas = (function () {
+ function GlslCanvas(canvas, options) {
+ var _this = this;
+
+ _classCallCheck(this, GlslCanvas);
+
+ (0, _toolsMixin.subscribeMixin)(this);
+
+ options = options || {};
+
+ this.width = canvas.clientWidth;
+ this.height = canvas.clientHeight;
+
+ this.canvas = canvas;
+ this.gl = undefined;
+ this.program = undefined;
+ this.uniforms = {};
+ this.vbo = {};
+ this.isValid = false;
+
+ this.vertexString = options.vertexString || '\n#ifdef GL_ES\nprecision mediump float;\n#endif\n\nattribute vec2 a_position;\nattribute vec2 a_texcoord;\n\nvarying vec2 v_texcoord;\n\nvoid main() {\n gl_Position = vec4(a_position, 0.0, 1.0);\n v_texcoord = a_texcoord;\n}\n';
+ this.fragmentString = options.fragmentString || '\n#ifdef GL_ES\nprecision mediump float;\n#endif\n\nvarying vec2 v_texcoord;\n\nvoid main(){\n gl_FragColor = vec4(0.0);\n}\n';
+
+ // GL Context
+ var gl = (0, _glGl.setupWebGL)(canvas, options);
+ if (!gl) {
+ return;
+ }
+ this.gl = gl;
+ this.timeLoad = Date.now();
+ this.forceRender = true;
+
+ // Allow alpha
+ canvas.style.backgroundColor = options.backgroundColor || 'rgba(1,1,1,0)';
+
+ // Load shader
+ if (canvas.hasAttribute('data-fragment')) {
+ this.fragmentString = canvas.getAttribute('data-fragment');
+ } else if (canvas.hasAttribute('data-fragment-url')) {
+ var source = canvas.getAttribute('data-fragment-url');
+ _xhr2['default'].get(source, function (error, response, body) {
+ _this.load(body, _this.vertexString);
+ });
+ }
+
+ // Load shader
+ if (canvas.hasAttribute('data-vertex')) {
+ this.vertexString = canvas.getAttribute('data-vertex');
+ } else if (canvas.hasAttribute('data-vertex-url')) {
+ var source = canvas.getAttribute('data-vertex-url');
+ _xhr2['default'].get(source, function (error, response, body) {
+ _this.load(_this.fragmentString, body);
+ });
+ }
+
+ this.load();
+
+ if (!this.program) {
+ return;
+ }
+
+ // Define Vertex buffer
+ var texCoordsLoc = gl.getAttribLocation(this.program, 'a_texcoord');
+ this.vbo.texCoords = gl.createBuffer();
+ this.gl.bindBuffer(gl.ARRAY_BUFFER, this.vbo.texCoords);
+ this.gl.bufferData(gl.ARRAY_BUFFER, new Float32Array([0.0, 0.0, 1.0, 0.0, 0.0, 1.0, 0.0, 1.0, 1.0, 0.0, 1.0, 1.0]), gl.STATIC_DRAW);
+ this.gl.enableVertexAttribArray(texCoordsLoc);
+ this.gl.vertexAttribPointer(texCoordsLoc, 2, gl.FLOAT, false, 0, 0);
+
+ var verticesLoc = gl.getAttribLocation(this.program, 'a_position');
+ this.vbo.vertices = gl.createBuffer();
+ this.gl.bindBuffer(gl.ARRAY_BUFFER, this.vbo.vertices);
+ this.gl.bufferData(gl.ARRAY_BUFFER, new Float32Array([-1.0, -1.0, 1.0, -1.0, -1.0, 1.0, -1.0, 1.0, 1.0, -1.0, 1.0, 1.0]), gl.STATIC_DRAW);
+ this.gl.enableVertexAttribArray(verticesLoc);
+ this.gl.vertexAttribPointer(verticesLoc, 2, gl.FLOAT, false, 0, 0);
+
+ // load TEXTURES
+ this.textures = {};
+ if (canvas.hasAttribute('data-textures')) {
+ var imgList = canvas.getAttribute('data-textures').split(',');
+ for (var nImg in imgList) {
+ this.setUniform('u_tex' + nImg, imgList[nImg]);
+ }
+ }
+
+ // ========================== EVENTS
+ var mouse = {
+ x: 0,
+ y: 0
+ };
+ document.addEventListener('mousemove', function (e) {
+ mouse.x = e.clientX || e.pageX;
+ mouse.y = e.clientY || e.pageY;
+ }, false);
+
+ var sandbox = this;
+ function RenderLoop() {
+ sandbox.setMouse(mouse);
+ sandbox.render();
+ sandbox.forceRender = sandbox.resize();
+ window.requestAnimationFrame(RenderLoop);
+ }
+
+ // Start
+ this.setMouse({ x: 0, y: 0 });
+ RenderLoop();
+ return this;
+ }
+
+ _createClass(GlslCanvas, [{
+ key: 'destroy',
+ value: function destroy() {
+ this.animated = false;
+ this.isValid = false;
+ for (var tex in this.textures) {
+ this.gl.deleteTexture(tex);
+ }
+ this.textures = {};
+ for (var att in this.attribs) {
+ this.gl.deleteBuffer(this.attribs[att]);
+ }
+ this.gl.useProgram(null);
+ this.gl.deleteProgram(this.program);
+ this.program = null;
+ this.gl = null;
+ }
+ }, {
+ key: 'load',
+ value: function load(fragString, vertString) {
+ // Load vertex shader if there is one
+ if (vertString) {
+ this.vertexString = vertString;
+ }
+
+ // Load fragment shader if there is one
+ if (fragString) {
+ this.fragmentString = fragString;
+ }
+
+ this.animated = false;
+ var nTimes = (this.fragmentString.match(/u_time/g) || []).length;
+ var nMouse = (this.fragmentString.match(/u_mouse/g) || []).length;
+ this.animated = nTimes > 1 || nMouse > 1;
+
+ var vertexShader = (0, _glGl.createShader)(this, this.vertexString, this.gl.VERTEX_SHADER);
+ var fragmentShader = (0, _glGl.createShader)(this, this.fragmentString, this.gl.FRAGMENT_SHADER);
+
+ // If Fragment shader fails load a empty one to sign the error
+ if (!fragmentShader) {
+ fragmentShader = (0, _glGl.createShader)(this, 'void main(){\n\tgl_FragColor = vec4(1.0);\n}', this.gl.FRAGMENT_SHADER);
+ this.isValid = false;
+ } else {
+ this.isValid = true;
+ }
+
+ // Create and use program
+ var program = (0, _glGl.createProgram)(this, [vertexShader, fragmentShader]); //, [0,1],['a_texcoord','a_position']);
+ this.gl.useProgram(program);
+
+ // Delete shaders
+ // this.gl.detachShader(program, vertexShader);
+ // this.gl.detachShader(program, fragmentShader);
+ this.gl.deleteShader(vertexShader);
+ this.gl.deleteShader(fragmentShader);
+
+ this.program = program;
+ this.change = true;
+
+ // Trigger event
+ this.trigger('load', {});
+
+ this.forceRender = true;
+ }
+ }, {
+ key: 'loadTexture',
+ value: function loadTexture(name, urlElementOrData, options) {
+ var _this2 = this;
+
+ if (!options) {
+ options = {};
+ }
+
+ if (typeof urlElementOrData === 'string') {
+ options.url = urlElementOrData;
+ } else if (typeof urlElementOrData === 'object' && urlElementOrData.data && urlElementOrData.width && urlElementOrData.height) {
+ options.data = urlElementOrData.data;
+ options.width = urlElementOrData.width;
+ options.height = urlElementOrData.height;
+ } else if (typeof urlElementOrData === 'object') {
+ options.element = urlElementOrData;
+ }
+ this.textures[name] = new _glTexture2['default'](this.gl, name, options);
+ this.textures[name].on('loaded', function (args) {
+ _this2.forceRender = true;
+ });
+ }
+ }, {
+ key: 'refreshUniforms',
+ value: function refreshUniforms() {
+ this.uniforms = {};
+ }
+ }, {
+ key: 'setUniform',
+ value: function setUniform(name) {
+ var u = {};
+
+ for (var _len = arguments.length, value = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
+ value[_key - 1] = arguments[_key];
+ }
+
+ u[name] = value;
+ this.setUniforms(u);
+ }
+ }, {
+ key: 'setUniforms',
+ value: function setUniforms(uniforms) {
+ var parsed = (0, _glGl.parseUniforms)(uniforms);
+ // Set each uniform
+ for (var u in parsed) {
+ if (parsed[u].type === 'sampler2D') {
+ // For textures, we need to track texture units, so we have a special setter
+ this.uniformTexture(parsed[u].name, parsed[u].value[0]);
+ } else {
+ this.uniform(parsed[u].method, parsed[u].type, parsed[u].name, parsed[u].value);
+ this.forceRender = true;
+ }
+ }
+ }
+ }, {
+ key: 'setMouse',
+ value: function setMouse(mouse) {
+ // set the mouse uniform
+ var rect = this.canvas.getBoundingClientRect();
+ if (mouse && mouse.x && mouse.x >= rect.left && mouse.x <= rect.right && mouse.y && mouse.y >= rect.top && mouse.y <= rect.bottom) {
+ this.uniform('2f', 'vec2', 'u_mouse', mouse.x - rect.left, this.canvas.height - (mouse.y - rect.top));
+ }
+ }
+
+ // ex: program.uniform('3f', 'position', x, y, z);
+ }, {
+ key: 'uniform',
+ value: function uniform(method, type, name) {
+ // 'value' is a method-appropriate arguments list
+ this.uniforms[name] = this.uniforms[name] || {};
+ var uniform = this.uniforms[name];
+
+ for (var _len2 = arguments.length, value = Array(_len2 > 3 ? _len2 - 3 : 0), _key2 = 3; _key2 < _len2; _key2++) {
+ value[_key2 - 3] = arguments[_key2];
+ }
+
+ var change = (0, _toolsCommon.isDiff)(uniform.value, value);
+ if (change || this.change || uniform.location === undefined || uniform.value === undefined) {
+ uniform.name = name;
+ uniform.value = value;
+ uniform.type = type;
+ uniform.method = 'uniform' + method;
+ uniform.location = this.gl.getUniformLocation(this.program, name);
+
+ this.gl[uniform.method].apply(this.gl, [uniform.location].concat(uniform.value));
+ }
+ }
+ }, {
+ key: 'uniformTexture',
+ value: function uniformTexture(name, texture, options) {
+ if (this.textures[name] === undefined) {
+ this.loadTexture(name, texture, options);
+ } else {
+ this.uniform('1i', 'sampler2D', name, this.texureIndex);
+ this.textures[name].bind(this.texureIndex);
+ this.uniform('2f', 'vec2', name + 'Resolution', this.textures[name].width, this.textures[name].height);
+ this.texureIndex++;
+ }
+ }
+ }, {
+ key: 'resize',
+ value: function resize() {
+ if (this.width !== this.canvas.clientWidth || this.height !== this.canvas.clientHeight) {
+ var realToCSSPixels = window.devicePixelRatio || 1;
+
+ // Lookup the size the browser is displaying the canvas in CSS pixels
+ // and compute a size needed to make our drawingbuffer match it in
+ // device pixels.
+ var displayWidth = Math.floor(this.gl.canvas.clientWidth * realToCSSPixels);
+ var displayHeight = Math.floor(this.gl.canvas.clientHeight * realToCSSPixels);
+
+ // Check if the canvas is not the same size.
+ if (this.gl.canvas.width !== displayWidth || this.gl.canvas.height !== displayHeight) {
+ // Make the canvas the same size
+ this.gl.canvas.width = displayWidth;
+ this.gl.canvas.height = displayHeight;
+ // Set the viewport to match
+ this.gl.viewport(0, 0, this.gl.canvas.width, this.gl.canvas.height);
+ // this.gl.viewport(0, 0, this.gl.drawingBufferWidth, this.gl.drawingBufferHeight);
+ }
+ this.width = this.canvas.clientWidth;
+ this.height = this.canvas.clientHeight;
+ return true;
+ } else {
+ return false;
+ }
+ }
+ }, {
+ key: 'render',
+ value: function render() {
+ this.visible = (0, _toolsCommon.isCanvasVisible)(this.canvas);
+ if (this.forceRender || this.animated && this.visible) {
+ // set the time uniform
+ var timeFrame = Date.now();
+ var time = (timeFrame - this.timeLoad) / 1000.0;
+ this.uniform('1f', 'float', 'u_time', time);
+
+ // set the resolution uniform
+ this.uniform('2f', 'vec2', 'u_resolution', this.canvas.width, this.canvas.height);
+
+ this.texureIndex = 0;
+ for (var tex in this.textures) {
+ this.uniformTexture(tex);
+ }
+
+ // Draw the rectangle.
+ this.gl.drawArrays(this.gl.TRIANGLES, 0, 6);
+
+ // Trigger event
+ this.trigger('render', {});
+
+ this.change = false;
+ this.forceRender = false;
+ }
+ }
+ }, {
+ key: 'version',
+ value: function version() {
+ return '0.0.3';
+ }
+ }]);
+
+ return GlslCanvas;
+})();
+
+exports['default'] = GlslCanvas;
+
+window.GlslCanvas = GlslCanvas;
+
+function loadAllGlslCanvas() {
+ var list = document.getElementsByClassName('glslCanvas');
+ if (list.length > 0) {
+ window.glslCanvases = [];
+ for (var i = 0; i < list.length; i++) {
+ var sandbox = new GlslCanvas(list[i]);
+ if (sandbox.isValid) {
+ window.glslCanvases.push(sandbox);
+ }
+ }
+ }
+}
+
+window.onload = function () {
+ loadAllGlslCanvas();
+};
+module.exports = exports['default'];
+
+},{"./gl/Texture":93,"./gl/gl":94,"./tools/common":95,"./tools/mixin":96,"babel-runtime/helpers/class-call-check":8,"babel-runtime/helpers/create-class":9,"babel-runtime/helpers/interop-require-default":10,"xhr":89}],93:[function(_dereq_,module,exports){
+// Texture management
+'use strict';
+
+var _createClass = _dereq_('babel-runtime/helpers/create-class')['default'];
+
+var _classCallCheck = _dereq_('babel-runtime/helpers/class-call-check')['default'];
+
+var _Promise = _dereq_('babel-runtime/core-js/promise')['default'];
+
+Object.defineProperty(exports, '__esModule', {
+ value: true
+});
+
+var _toolsCommon = _dereq_('../tools/common');
+
+var _toolsMixin = _dereq_('../tools/mixin');
+
+// GL texture wrapper object for keeping track of a global set of textures, keyed by a unique user-defined name
+
+var Texture = (function () {
+ function Texture(gl, name) {
+ var options = arguments.length <= 2 || arguments[2] === undefined ? {} : arguments[2];
+
+ _classCallCheck(this, Texture);
+
+ (0, _toolsMixin.subscribeMixin)(this);
+
+ this.gl = gl;
+ this.texture = gl.createTexture();
+ if (this.texture) {
+ this.valid = true;
+ }
+ this.bind();
+
+ this.name = name;
+ this.source = null;
+ this.sourceType = null;
+ this.loading = null; // a Promise object to track the loading state of this texture
+
+ // Default to a 1-pixel black texture so we can safely render while we wait for an image to load
+ // See: http://stackoverflow.com/questions/19722247/webgl-wait-for-texture-to-load
+ this.setData(1, 1, new Uint8Array([0, 0, 0, 255]), { filtering: 'linear' });
+ this.setFiltering(options.filtering);
+
+ this.load(options);
+ }
+
+ // Report max texture size for a GL context
+
+ // Destroy a single texture instance
+
+ _createClass(Texture, [{
+ key: 'destroy',
+ value: function destroy() {
+ if (!this.valid) {
+ return;
+ }
+ this.gl.deleteTexture(this.texture);
+ this.texture = null;
+ delete this.data;
+ this.data = null;
+ this.valid = false;
+ }
+ }, {
+ key: 'bind',
+ value: function bind(unit) {
+ if (!this.valid) {
+ return;
+ }
+ if (typeof unit === 'number') {
+ if (Texture.activeUnit !== unit) {
+ this.gl.activeTexture(this.gl.TEXTURE0 + unit);
+ Texture.activeUnit = unit;
+ }
+ }
+ if (Texture.activeTexture !== this.texture) {
+ this.gl.bindTexture(this.gl.TEXTURE_2D, this.texture);
+ Texture.activeTexture = this.texture;
+ }
+ }
+ }, {
+ key: 'load',
+ value: function load() {
+ var options = arguments.length <= 0 || arguments[0] === undefined ? {} : arguments[0];
+
+ this.loading = null;
+
+ if (typeof options.url === 'string') {
+ this.setUrl(options.url, options);
+ } else if (options.element) {
+ this.setElement(options.element, options);
+ } else if (options.data && options.width && options.height) {
+ this.setData(options.width, options.height, options.data, options);
+ }
+ }
+
+ // Sets texture from an url
+ }, {
+ key: 'setUrl',
+ value: function setUrl(url) {
+ var _this = this;
+
+ var options = arguments.length <= 1 || arguments[1] === undefined ? {} : arguments[1];
+
+ if (!this.valid) {
+ return;
+ }
+
+ this.url = url; // save URL reference (will be overwritten when element is loaded below)
+ this.source = this.url;
+ this.sourceType = 'url';
+
+ this.loading = new _Promise(function (resolve, reject) {
+ var image = new Image();
+ image.onload = function () {
+ try {
+ _this.setElement(image, options);
+ } catch (e) {
+ console.log('Texture \'' + _this.name + '\': failed to load url: \'' + _this.source + '\'', e, options);
+ }
+
+ resolve(_this);
+ };
+ image.onerror = function (e) {
+ // Warn and resolve on error
+ console.log('Texture \'' + _this.name + '\': failed to load url: \'' + _this.source + '\'', e, options);
+ resolve(_this);
+ };
+ image.crossOrigin = 'anonymous';
+ image.src = _this.source;
+ });
+ return this.loading;
+ }
+
+ // Sets texture to a raw image buffer
+ }, {
+ key: 'setData',
+ value: function setData(width, height, data) {
+ var options = arguments.length <= 3 || arguments[3] === undefined ? {} : arguments[3];
+
+ this.width = width;
+ this.height = height;
+
+ this.source = data;
+ this.sourceType = 'data';
+
+ this.update(options);
+ this.setFiltering(options);
+
+ this.loading = _Promise.resolve(this);
+ return this.loading;
+ }
+
+ // Sets the texture to track a element (canvas/image)
+ }, {
+ key: 'setElement',
+ value: function setElement(element, options) {
+ var el = element;
+
+ // a string element is interpeted as a CSS selector
+ if (typeof element === 'string') {
+ element = document.querySelector(element);
+ }
+
+ if (element instanceof HTMLCanvasElement || element instanceof HTMLImageElement || element instanceof HTMLVideoElement) {
+ this.source = element;
+ this.sourceType = 'element';
+
+ this.update(options);
+ this.setFiltering(options);
+ } else {
+ var msg = 'the \'element\' parameter (`element: ' + JSON.stringify(el) + '`) must be a CSS ';
+ msg += 'selector string, or a , or object';
+ console.log('Texture \'' + this.name + '\': ' + msg, options);
+ }
+
+ this.loading = _Promise.resolve(this);
+ return this.loading;
+ }
+
+ // Uploads current image or buffer to the GPU (can be used to update animated textures on the fly)
+ }, {
+ key: 'update',
+ value: function update() {
+ var options = arguments.length <= 0 || arguments[0] === undefined ? {} : arguments[0];
+
+ if (!this.valid) {
+ return;
+ }
+
+ this.bind();
+ this.gl.pixelStorei(this.gl.UNPACK_FLIP_Y_WEBGL, options.UNPACK_FLIP_Y_WEBGL === false ? false : true);
+ this.gl.pixelStorei(this.gl.UNPACK_PREMULTIPLY_ALPHA_WEBGL, options.UNPACK_PREMULTIPLY_ALPHA_WEBGL || false);
+
+ // Image or Canvas element
+ if (this.sourceType === 'element' && (this.source instanceof HTMLCanvasElement || this.source instanceof HTMLVideoElement || this.source instanceof HTMLImageElement && this.source.complete)) {
+ this.width = this.source.width;
+ this.height = this.source.height;
+ this.gl.texImage2D(this.gl.TEXTURE_2D, 0, this.gl.RGBA, this.gl.RGBA, this.gl.UNSIGNED_BYTE, this.source);
+ }
+ // Raw image buffer
+ else if (this.sourceType === 'data') {
+ this.gl.texImage2D(this.gl.TEXTURE_2D, 0, this.gl.RGBA, this.width, this.height, 0, this.gl.RGBA, this.gl.UNSIGNED_BYTE, this.source);
+ }
+ this.trigger('loaded', this);
+ }
+
+ // Determines appropriate filtering mode
+ }, {
+ key: 'setFiltering',
+ value: function setFiltering() {
+ var options = arguments.length <= 0 || arguments[0] === undefined ? {} : arguments[0];
+
+ if (!this.valid) {
+ return;
+ }
+
+ this.powerOf2 = (0, _toolsCommon.isPowerOf2)(this.width) && (0, _toolsCommon.isPowerOf2)(this.height);
+ var defualtFilter = this.powerOf2 ? 'mipmap' : 'linear';
+ this.filtering = options.filtering || defualtFilter;
+
+ var gl = this.gl;
+ this.bind();
+
+ // For power-of-2 textures, the following presets are available:
+ // mipmap: linear blend from nearest mip
+ // linear: linear blend from original image (no mips)
+ // nearest: nearest pixel from original image (no mips, 'blocky' look)
+ if (this.powerOf2) {
+ gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, options.TEXTURE_WRAP_S || options.repeat && gl.REPEAT || gl.CLAMP_TO_EDGE);
+ gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, options.TEXTURE_WRAP_T || options.repeat && gl.REPEAT || gl.CLAMP_TO_EDGE);
+
+ if (this.filtering === 'mipmap') {
+ gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR_MIPMAP_LINEAR); // TODO: use trilinear filtering by defualt instead?
+ gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.LINEAR);
+ gl.generateMipmap(gl.TEXTURE_2D);
+ } else if (this.filtering === 'linear') {
+ gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR);
+ gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.LINEAR);
+ } else if (this.filtering === 'nearest') {
+ gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.NEAREST);
+ gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.NEAREST);
+ }
+ } else {
+ // WebGL has strict requirements on non-power-of-2 textures:
+ // No mipmaps and must clamp to edge
+ gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE);
+ gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE);
+
+ if (this.filtering === 'mipmap') {
+ this.filtering = 'linear';
+ }
+
+ if (this.filtering === 'nearest') {
+ gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.NEAREST);
+ gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.NEAREST);
+ } else {
+ // default to linear for non-power-of-2 textures
+ gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR);
+ gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.LINEAR);
+ }
+ }
+ }
+ }]);
+
+ return Texture;
+})();
+
+exports['default'] = Texture;
+Texture.getMaxTextureSize = function (gl) {
+ return gl.getParameter(gl.MAX_TEXTURE_SIZE);
+};
+
+// Global set of textures, by name
+Texture.activeUnit = -1;
+module.exports = exports['default'];
+
+},{"../tools/common":95,"../tools/mixin":96,"babel-runtime/core-js/promise":6,"babel-runtime/helpers/class-call-check":8,"babel-runtime/helpers/create-class":9}],94:[function(_dereq_,module,exports){
+'use strict';
+
+var _toConsumableArray = _dereq_('babel-runtime/helpers/to-consumable-array')['default'];
+
+Object.defineProperty(exports, '__esModule', {
+ value: true
+});
+exports.setupWebGL = setupWebGL;
+exports.create3DContext = create3DContext;
+exports.createShader = createShader;
+exports.createProgram = createProgram;
+exports.parseUniforms = parseUniforms;
+var lastError = '';
+
+/**
+ * Creates the HTLM for a failure message
+ * @param {string} canvasContainerId id of container of th
+ * canvas.
+ * @return {string} The html.
+ */
+function makeFailHTML(msg) {
+ return '\n\n';
+}
+
+/**
+ * Mesasge for getting a webgl browser
+ * @type {string}
+ */
+var GET_A_WEBGL_BROWSER = '\n\tThis page requires a browser that supports WebGL. \n\tClick here to upgrade your browser. \n';
+
+/**
+ * Mesasge for need better hardware
+ * @type {string}
+ */
+var OTHER_PROBLEM = '\n\tIt does not appear your computer can support WebGL. \n\tClick here for more information. \n';
+
+/**
+ * Creates a webgl context. If creation fails it will
+ * change the contents of the container of the
+ * tag to an error message with the correct links for WebGL.
+ * @param {Element} canvas. The canvas element to create a
+ * context from.
+ * @param {WebGLContextCreationAttirbutes} optAttribs Any
+ * creation attributes you want to pass in.
+ * @return {WebGLRenderingContext} The created context.
+ */
+
+function setupWebGL(canvas, optAttribs) {
+ function showLink(str) {
+ var container = canvas.parentNode;
+ if (container) {
+ container.innerHTML = makeFailHTML(str);
+ }
+ }
+
+ if (!window.WebGLRenderingContext) {
+ showLink(GET_A_WEBGL_BROWSER);
+ return null;
+ }
+
+ var context = create3DContext(canvas, optAttribs);
+ if (!context) {
+ showLink(OTHER_PROBLEM);
+ }
+ context.getExtension('OES_standard_derivatives');
+ return context;
+}
+
+/**
+ * Creates a webgl context.
+ * @param {!Canvas} canvas The canvas tag to get context
+ * from. If one is not passed in one will be created.
+ * @return {!WebGLContext} The created context.
+ */
+
+function create3DContext(canvas, optAttribs) {
+ var names = ['webgl', 'experimental-webgl'];
+ var context = null;
+ for (var ii = 0; ii < names.length; ++ii) {
+ try {
+ context = canvas.getContext(names[ii], optAttribs);
+ } catch (e) {
+ if (context) {
+ break;
+ }
+ }
+ }
+ return context;
+}
+
+/*
+ * Create a Vertex of a specific type (gl.VERTEX_SHADER/)
+ */
+
+function createShader(main, source, type) {
+ var gl = main.gl;
+
+ var shader = gl.createShader(type);
+ gl.shaderSource(shader, source);
+ gl.compileShader(shader);
+
+ var compiled = gl.getShaderParameter(shader, gl.COMPILE_STATUS);
+
+ if (!compiled) {
+ // Something went wrong during compilation; get the error
+ lastError = gl.getShaderInfoLog(shader);
+ console.error('*** Error compiling shader ' + shader + ':' + lastError);
+ main.trigger('error', { shader: shader, source: source, type: type, error: lastError });
+ gl.deleteShader(shader);
+ return null;
+ }
+
+ return shader;
+}
+
+/**
+ * Loads a shader.
+ * @param {!WebGLContext} gl The WebGLContext to use.
+ * @param {string} shaderSource The shader source.
+ * @param {number} shaderType The type of shader.
+ * @param {function(string): void) opt_errorCallback callback for errors.
+ * @return {!WebGLShader} The created shader.
+ */
+
+function createProgram(main, shaders, optAttribs, optLocations) {
+ var gl = main.gl;
+
+ var program = gl.createProgram();
+ for (var ii = 0; ii < shaders.length; ++ii) {
+ gl.attachShader(program, shaders[ii]);
+ }
+ if (optAttribs) {
+ for (var ii = 0; ii < optAttribs.length; ++ii) {
+ gl.bindAttribLocation(program, optLocations ? optLocations[ii] : ii, optAttribs[ii]);
+ }
+ }
+ gl.linkProgram(program);
+
+ // Check the link status
+ var linked = gl.getProgramParameter(program, gl.LINK_STATUS);
+ if (!linked) {
+ // something went wrong with the link
+ lastError = gl.getProgramInfoLog(program);
+ console.log('Error in program linking:' + lastError);
+ gl.deleteProgram(program);
+ return null;
+ }
+ return program;
+}
+
+// By Brett Camber on
+// https://github.com/tangrams/tangram/blob/master/src/gl/glsl.js
+
+function parseUniforms(uniforms) {
+ var prefix = arguments.length <= 1 || arguments[1] === undefined ? null : arguments[1];
+
+ var parsed = [];
+
+ for (var _name in uniforms) {
+ var uniform = uniforms[_name];
+ var u = undefined;
+
+ if (prefix) {
+ _name = prefix + '.' + _name;
+ }
+
+ // Single float
+ if (typeof uniform === 'number') {
+ parsed.push({
+ type: 'float',
+ method: '1f',
+ name: _name,
+ value: uniform
+ });
+ }
+ // Array: vector, array of floats, array of textures, or array of structs
+ else if (Array.isArray(uniform)) {
+ // Numeric values
+ if (typeof uniform[0] === 'number') {
+ // float vectors (vec2, vec3, vec4)
+ if (uniform.length === 1) {
+ parsed.push({
+ type: 'float',
+ method: '1f',
+ name: _name,
+ value: uniform
+ });
+ }
+ // float vectors (vec2, vec3, vec4)
+ else if (uniform.length >= 2 && uniform.length <= 4) {
+ parsed.push({
+ type: 'vec' + uniform.length,
+ method: uniform.length + 'fv',
+ name: _name,
+ value: uniform
+ });
+ }
+ // float array
+ else if (uniform.length > 4) {
+ parsed.push({
+ type: 'float[]',
+ method: '1fv',
+ name: _name + '[0]',
+ value: uniform
+ });
+ }
+ // TODO: assume matrix for (typeof == Float32Array && length == 16)?
+ }
+ // Array of textures
+ else if (typeof uniform[0] === 'string') {
+ parsed.push({
+ type: 'sampler2D',
+ method: '1i',
+ name: _name,
+ value: uniform
+ });
+ }
+ // Array of arrays - but only arrays of vectors are allowed in this case
+ else if (Array.isArray(uniform[0]) && typeof uniform[0][0] === 'number') {
+ // float vectors (vec2, vec3, vec4)
+ if (uniform[0].length >= 2 && uniform[0].length <= 4) {
+ // Set each vector in the array
+ for (u = 0; u < uniform.length; u++) {
+ parsed.push({
+ type: 'vec' + uniform[0].length,
+ method: uniform[u].length + 'fv',
+ name: _name + '[' + u + ']',
+ value: uniform[u]
+ });
+ }
+ }
+ // else error?
+ }
+ // Array of structures
+ else if (typeof uniform[0] === 'object') {
+ for (u = 0; u < uniform.length; u++) {
+ // Set each struct in the array
+ parsed.push.apply(parsed, _toConsumableArray(parseUniforms(uniform[u], _name + '[' + u + ']')));
+ }
+ }
+ }
+ // Boolean
+ else if (typeof uniform === 'boolean') {
+ parsed.push({
+ type: 'bool',
+ method: '1i',
+ name: _name,
+ value: uniform
+ });
+ }
+ // Texture
+ else if (typeof uniform === 'string') {
+ parsed.push({
+ type: 'sampler2D',
+ method: '1i',
+ name: _name,
+ value: uniform
+ });
+ }
+ // Structure
+ else if (typeof uniform === 'object') {
+ // Set each field in the struct
+ parsed.push.apply(parsed, _toConsumableArray(parseUniforms(uniform, _name)));
+ }
+ // TODO: support other non-float types? (int, etc.)
+ }
+ return parsed;
+}
+
+},{"babel-runtime/helpers/to-consumable-array":11}],95:[function(_dereq_,module,exports){
+'use strict';
+
+var _Set = _dereq_('babel-runtime/core-js/set')['default'];
+
+var _Object$assign = _dereq_('babel-runtime/core-js/object/assign')['default'];
+
+var _getIterator = _dereq_('babel-runtime/core-js/get-iterator')['default'];
+
+Object.defineProperty(exports, '__esModule', {
+ value: true
+});
+exports.isCanvasVisible = isCanvasVisible;
+exports.isPowerOf2 = isPowerOf2;
+exports.nextHighestPowerOfTwo = nextHighestPowerOfTwo;
+exports.FormatNumberLength = FormatNumberLength;
+exports.getMousePos = getMousePos;
+exports.isDiff = isDiff;
+exports.subscribeMixin = subscribeMixin;
+
+function isCanvasVisible(canvas) {
+ return canvas.getBoundingClientRect().top + canvas.height > 0 && canvas.getBoundingClientRect().top < (window.innerHeight || document.documentElement.clientHeight);
+}
+
+function isPowerOf2(value) {
+ return (value & value - 1) === 0;
+}
+
+function nextHighestPowerOfTwo(x) {
+ --x;
+ for (var i = 1; i < 32; i <<= 1) {
+ x = x | x >> i;
+ }
+ return x + 1;
+}
+
+function FormatNumberLength(num, length) {
+ var r = num.toString();
+ while (r.length < length) {
+ r = '0' + r;
+ }
+ return r;
+}
+
+function getMousePos(canvas, evt) {
+ var rect = canvas.getBoundingClientRect();
+ return {
+ x: evt.clientX - rect.left,
+ y: evt.clientY - rect.top
+ };
+}
+
+function isDiff(a, b) {
+ if (a && b) {
+ return a.toString() !== b.toString();
+ }
+ return false;
+}
+
+function subscribeMixin(target) {
+ var listeners = new _Set();
+
+ return _Object$assign(target, {
+
+ subscribe: function subscribe(listener) {
+ listeners.add(listener);
+ },
+
+ on: function on(type, f) {
+ var listener = {};
+ listener[type] = f;
+ listeners.add(listener);
+ },
+
+ unsubscribe: function unsubscribe(listener) {
+ listeners['delete'](listener);
+ },
+
+ unsubscribeAll: function unsubscribeAll() {
+ listeners.clear();
+ },
+
+ trigger: function trigger(event) {
+ var _iteratorNormalCompletion = true;
+ var _didIteratorError = false;
+ var _iteratorError = undefined;
+
+ try {
+ for (var _len = arguments.length, data = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
+ data[_key - 1] = arguments[_key];
+ }
+
+ for (var _iterator = _getIterator(listeners), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {
+ var listener = _step.value;
+
+ if (typeof listener[event] === 'function') {
+ listener[event].apply(listener, data);
+ }
+ }
+ } catch (err) {
+ _didIteratorError = true;
+ _iteratorError = err;
+ } finally {
+ try {
+ if (!_iteratorNormalCompletion && _iterator['return']) {
+ _iterator['return']();
+ }
+ } finally {
+ if (_didIteratorError) {
+ throw _iteratorError;
+ }
+ }
+ }
+ }
+ });
+}
+
+},{"babel-runtime/core-js/get-iterator":2,"babel-runtime/core-js/object/assign":3,"babel-runtime/core-js/set":7}],96:[function(_dereq_,module,exports){
+'use strict';
+
+var _Set = _dereq_('babel-runtime/core-js/set')['default'];
+
+var _Object$assign = _dereq_('babel-runtime/core-js/object/assign')['default'];
+
+var _getIterator = _dereq_('babel-runtime/core-js/get-iterator')['default'];
+
+var _Object$keys = _dereq_('babel-runtime/core-js/object/keys')['default'];
+
+Object.defineProperty(exports, '__esModule', {
+ value: true
+});
+exports.subscribeMixin = subscribeMixin;
+
+function subscribeMixin(target) {
+ var listeners = new _Set();
+
+ return _Object$assign(target, {
+
+ on: function on(type, f) {
+ var listener = {};
+ listener[type] = f;
+ listeners.add(listener);
+ },
+
+ off: function off(type, f) {
+ if (f) {
+ var listener = {};
+ listener[type] = f;
+ listeners['delete'](listener);
+ } else {
+ var _iteratorNormalCompletion = true;
+ var _didIteratorError = false;
+ var _iteratorError = undefined;
+
+ try {
+ for (var _iterator = _getIterator(listeners), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {
+ var item = _step.value;
+ var _iteratorNormalCompletion2 = true;
+ var _didIteratorError2 = false;
+ var _iteratorError2 = undefined;
+
+ try {
+ for (var _iterator2 = _getIterator(_Object$keys(item)), _step2; !(_iteratorNormalCompletion2 = (_step2 = _iterator2.next()).done); _iteratorNormalCompletion2 = true) {
+ var key = _step2.value;
+
+ if (key === type) {
+ listeners['delete'](item);
+ return;
+ }
+ }
+ } catch (err) {
+ _didIteratorError2 = true;
+ _iteratorError2 = err;
+ } finally {
+ try {
+ if (!_iteratorNormalCompletion2 && _iterator2['return']) {
+ _iterator2['return']();
+ }
+ } finally {
+ if (_didIteratorError2) {
+ throw _iteratorError2;
+ }
+ }
+ }
+ }
+ } catch (err) {
+ _didIteratorError = true;
+ _iteratorError = err;
+ } finally {
+ try {
+ if (!_iteratorNormalCompletion && _iterator['return']) {
+ _iterator['return']();
+ }
+ } finally {
+ if (_didIteratorError) {
+ throw _iteratorError;
+ }
+ }
+ }
+ }
+ },
+
+ listSubscriptions: function listSubscriptions() {
+ var _iteratorNormalCompletion3 = true;
+ var _didIteratorError3 = false;
+ var _iteratorError3 = undefined;
+
+ try {
+ for (var _iterator3 = _getIterator(listeners), _step3; !(_iteratorNormalCompletion3 = (_step3 = _iterator3.next()).done); _iteratorNormalCompletion3 = true) {
+ var item = _step3.value;
+
+ console.log(item);
+ }
+ } catch (err) {
+ _didIteratorError3 = true;
+ _iteratorError3 = err;
+ } finally {
+ try {
+ if (!_iteratorNormalCompletion3 && _iterator3['return']) {
+ _iterator3['return']();
+ }
+ } finally {
+ if (_didIteratorError3) {
+ throw _iteratorError3;
+ }
+ }
+ }
+ },
+
+ subscribe: function subscribe(listener) {
+ listeners.add(listener);
+ },
+
+ unsubscribe: function unsubscribe(listener) {
+ listeners['delete'](listener);
+ },
+
+ unsubscribeAll: function unsubscribeAll() {
+ listeners.clear();
+ },
+
+ trigger: function trigger(event) {
+ var _iteratorNormalCompletion4 = true;
+ var _didIteratorError4 = false;
+ var _iteratorError4 = undefined;
+
+ try {
+ for (var _len = arguments.length, data = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
+ data[_key - 1] = arguments[_key];
+ }
+
+ for (var _iterator4 = _getIterator(listeners), _step4; !(_iteratorNormalCompletion4 = (_step4 = _iterator4.next()).done); _iteratorNormalCompletion4 = true) {
+ var listener = _step4.value;
+
+ if (typeof listener[event] === 'function') {
+ listener[event].apply(listener, data);
+ }
+ }
+ } catch (err) {
+ _didIteratorError4 = true;
+ _iteratorError4 = err;
+ } finally {
+ try {
+ if (!_iteratorNormalCompletion4 && _iterator4['return']) {
+ _iterator4['return']();
+ }
+ } finally {
+ if (_didIteratorError4) {
+ throw _iteratorError4;
+ }
+ }
+ }
+ }
+ });
+}
+
+},{"babel-runtime/core-js/get-iterator":2,"babel-runtime/core-js/object/assign":3,"babel-runtime/core-js/object/keys":5,"babel-runtime/core-js/set":7}]},{},[92])(92)
+});
+
+
+}).call(this,typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {})
+
+},{}],10:[function(_dereq_,module,exports){
+module.exports = isFunction
+
+var toString = Object.prototype.toString
+
+function isFunction (fn) {
+ var string = toString.call(fn)
+ return string === '[object Function]' ||
+ (typeof fn === 'function' && string !== '[object RegExp]') ||
+ (typeof window !== 'undefined' &&
+ // IE8 and below
+ (fn === window.setTimeout ||
+ fn === window.alert ||
+ fn === window.confirm ||
+ fn === window.prompt))
+};
+
+},{}],11:[function(_dereq_,module,exports){
+var trim = _dereq_('trim')
+ , forEach = _dereq_('for-each')
+ , isArray = function(arg) {
+ return Object.prototype.toString.call(arg) === '[object Array]';
+ }
+
+module.exports = function (headers) {
+ if (!headers)
+ return {}
+
+ var result = {}
+
+ forEach(
+ trim(headers).split('\n')
+ , function (row) {
+ var index = row.indexOf(':')
+ , key = trim(row.slice(0, index)).toLowerCase()
+ , value = trim(row.slice(index + 1))
+
+ if (typeof(result[key]) === 'undefined') {
+ result[key] = value
+ } else if (isArray(result[key])) {
+ result[key].push(value)
+ } else {
+ result[key] = [ result[key], value ]
+ }
+ }
+ )
+
+ return result
+}
+},{"for-each":7,"trim":12}],12:[function(_dereq_,module,exports){
+
+exports = module.exports = trim;
+
+function trim(str){
+ return str.replace(/^\s*|\s*$/g, '');
+}
+
+exports.left = function(str){
+ return str.replace(/^\s*/, '');
+};
+
+exports.right = function(str){
+ return str.replace(/\s*$/, '');
+};
+
+},{}],13:[function(_dereq_,module,exports){
+"use strict";
+var window = _dereq_("global/window")
+var once = _dereq_("once")
+var isFunction = _dereq_("is-function")
+var parseHeaders = _dereq_("parse-headers")
+var xtend = _dereq_("xtend")
+
+module.exports = createXHR
+createXHR.XMLHttpRequest = window.XMLHttpRequest || noop
+createXHR.XDomainRequest = "withCredentials" in (new createXHR.XMLHttpRequest()) ? createXHR.XMLHttpRequest : window.XDomainRequest
+
+forEachArray(["get", "put", "post", "patch", "head", "delete"], function(method) {
+ createXHR[method === "delete" ? "del" : method] = function(uri, options, callback) {
+ options = initParams(uri, options, callback)
+ options.method = method.toUpperCase()
+ return _createXHR(options)
+ }
+})
+
+function forEachArray(array, iterator) {
+ for (var i = 0; i < array.length; i++) {
+ iterator(array[i])
+ }
+}
+
+function isEmpty(obj){
+ for(var i in obj){
+ if(obj.hasOwnProperty(i)) return false
+ }
+ return true
+}
+
+function initParams(uri, options, callback) {
+ var params = uri
+
+ if (isFunction(options)) {
+ callback = options
+ if (typeof uri === "string") {
+ params = {uri:uri}
+ }
+ } else {
+ params = xtend(options, {uri: uri})
+ }
+
+ params.callback = callback
+ return params
+}
+
+function createXHR(uri, options, callback) {
+ options = initParams(uri, options, callback)
+ return _createXHR(options)
+}
+
+function _createXHR(options) {
+ var callback = options.callback
+ if(typeof callback === "undefined"){
+ throw new Error("callback argument missing")
+ }
+ callback = once(callback)
+
+ function readystatechange() {
+ if (xhr.readyState === 4) {
+ loadFunc()
+ }
+ }
+
+ function getBody() {
+ // Chrome with requestType=blob throws errors arround when even testing access to responseText
+ var body = undefined
+
+ if (xhr.response) {
+ body = xhr.response
+ } else if (xhr.responseType === "text" || !xhr.responseType) {
+ body = xhr.responseText || xhr.responseXML
+ }
+
+ if (isJson) {
+ try {
+ body = JSON.parse(body)
+ } catch (e) {}
+ }
+
+ return body
+ }
+
+ var failureResponse = {
+ body: undefined,
+ headers: {},
+ statusCode: 0,
+ method: method,
+ url: uri,
+ rawRequest: xhr
+ }
+
+ function errorFunc(evt) {
+ clearTimeout(timeoutTimer)
+ if(!(evt instanceof Error)){
+ evt = new Error("" + (evt || "Unknown XMLHttpRequest Error") )
+ }
+ evt.statusCode = 0
+ callback(evt, failureResponse)
+ }
+
+ // will load the data & process the response in a special response object
+ function loadFunc() {
+ if (aborted) return
+ var status
+ clearTimeout(timeoutTimer)
+ if(options.useXDR && xhr.status===undefined) {
+ //IE8 CORS GET successful response doesn't have a status field, but body is fine
+ status = 200
+ } else {
+ status = (xhr.status === 1223 ? 204 : xhr.status)
+ }
+ var response = failureResponse
+ var err = null
+
+ if (status !== 0){
+ response = {
+ body: getBody(),
+ statusCode: status,
+ method: method,
+ headers: {},
+ url: uri,
+ rawRequest: xhr
+ }
+ if(xhr.getAllResponseHeaders){ //remember xhr can in fact be XDR for CORS in IE
+ response.headers = parseHeaders(xhr.getAllResponseHeaders())
+ }
+ } else {
+ err = new Error("Internal XMLHttpRequest Error")
+ }
+ callback(err, response, response.body)
+
+ }
+
+ var xhr = options.xhr || null
+
+ if (!xhr) {
+ if (options.cors || options.useXDR) {
+ xhr = new createXHR.XDomainRequest()
+ }else{
+ xhr = new createXHR.XMLHttpRequest()
+ }
+ }
+
+ var key
+ var aborted
+ var uri = xhr.url = options.uri || options.url
+ var method = xhr.method = options.method || "GET"
+ var body = options.body || options.data || null
+ var headers = xhr.headers = options.headers || {}
+ var sync = !!options.sync
+ var isJson = false
+ var timeoutTimer
+
+ if ("json" in options) {
+ isJson = true
+ headers["accept"] || headers["Accept"] || (headers["Accept"] = "application/json") //Don't override existing accept header declared by user
+ if (method !== "GET" && method !== "HEAD") {
+ headers["content-type"] || headers["Content-Type"] || (headers["Content-Type"] = "application/json") //Don't override existing accept header declared by user
+ body = JSON.stringify(options.json)
+ }
+ }
+
+ xhr.onreadystatechange = readystatechange
+ xhr.onload = loadFunc
+ xhr.onerror = errorFunc
+ // IE9 must have onprogress be set to a unique function.
+ xhr.onprogress = function () {
+ // IE must die
+ }
+ xhr.ontimeout = errorFunc
+ xhr.open(method, uri, !sync, options.username, options.password)
+ //has to be after open
+ if(!sync) {
+ xhr.withCredentials = !!options.withCredentials
+ }
+ // Cannot set timeout with sync request
+ // not setting timeout on the xhr object, because of old webkits etc. not handling that correctly
+ // both npm's request and jquery 1.x use this kind of timeout, so this is being consistent
+ if (!sync && options.timeout > 0 ) {
+ timeoutTimer = setTimeout(function(){
+ aborted=true//IE9 may still call readystatechange
+ xhr.abort("timeout")
+ var e = new Error("XMLHttpRequest timeout")
+ e.code = "ETIMEDOUT"
+ errorFunc(e)
+ }, options.timeout )
+ }
+
+ if (xhr.setRequestHeader) {
+ for(key in headers){
+ if(headers.hasOwnProperty(key)){
+ xhr.setRequestHeader(key, headers[key])
+ }
+ }
+ } else if (options.headers && !isEmpty(options.headers)) {
+ throw new Error("Headers cannot be set on an XDomainRequest object")
+ }
+
+ if ("responseType" in options) {
+ xhr.responseType = options.responseType
+ }
+
+ if ("beforeSend" in options &&
+ typeof options.beforeSend === "function"
+ ) {
+ options.beforeSend(xhr)
+ }
+
+ xhr.send(body)
+
+ return xhr
+
+
+}
+
+function noop() {}
+
+},{"global/window":8,"is-function":10,"once":14,"parse-headers":11,"xtend":15}],14:[function(_dereq_,module,exports){
+module.exports = once
+
+once.proto = once(function () {
+ Object.defineProperty(Function.prototype, 'once', {
+ value: function () {
+ return once(this)
+ },
+ configurable: true
+ })
+})
+
+function once (fn) {
+ var called = false
+ return function () {
+ if (called) return
+ called = true
+ return fn.apply(this, arguments)
+ }
+}
+
+},{}],15:[function(_dereq_,module,exports){
+module.exports = extend
+
+var hasOwnProperty = Object.prototype.hasOwnProperty;
+
+function extend() {
+ var target = {}
+
+ for (var i = 0; i < arguments.length; i++) {
+ var source = arguments[i]
+
+ for (var key in source) {
+ if (hasOwnProperty.call(source, key)) {
+ target[key] = source[key]
+ }
+ }
+ }
+
+ return target
+}
+
+},{}],16:[function(_dereq_,module,exports){
+'use strict';
+
+var _classCallCheck = _dereq_('babel-runtime/helpers/class-call-check')['default'];
+
+Object.defineProperty(exports, '__esModule', {
+ value: true
+});
+exports.createOpenFrameArtwork = createOpenFrameArtwork;
+
+var OpenFrameIcon = function OpenFrameIcon(parent) {
+ var _this = this;
+
+ _classCallCheck(this, OpenFrameIcon);
+
+ this.parent = parent;
+
+ this.el = document.createElement('div');
+ this.el.setAttribute('class', 'glslGallery_openFrameIcon');
+ this.el.innerHTML = '[o]';
+ this.el.addEventListener('click', function () {
+ createOpenFrameArtwork(_this.parent, function () {
+ console.log(event);
+ });
+ }, true);
+
+ this.parent.el.appendChild(this.el);
+};
+
+exports['default'] = OpenFrameIcon;
+
+function createOpenFrameArtwork(item, callback) {
+ var id = item.id;
+ var title = item.title || 'unknow';
+ var author = item.author || 'unknow';
+ var xhr = new XMLHttpRequest();
+ callback = callback || function () {};
+ // anywhere in the API that user {id} is needed, the alias 'current' can be used for the logged-in user
+ xhr.open('POST', 'http://openframe.io/api/users/current/owned_artwork', false);
+ // set content type to JSON...
+ xhr.setRequestHeader('Content-Type', 'application/json;charset=UTF-8');
+ // This is essential in order to include auth cookies:
+ xhr.withCredentials = true;
+ xhr.onload = function (event) {
+ if (event.currentTarget.status === 404) {
+ (function () {
+ window.open('http://openframe.io/login-popup', 'login', 'width=500,height=600');
+ var successListener = function successListener(e) {
+ if (e.data === 'success') {
+ createOpenFrameArtwork(item, callback);
+ }
+ window.removeEventListener('message', successListener);
+ };
+ window.addEventListener('message', successListener, false);
+ })();
+ } else if (event.currentTarget.status === 200) {
+ callback(true);
+ } else {
+ callback(false);
+ }
+ };
+ xhr.onerror = function (event) {
+ console.log(event.currentTarget.status);
+ };
+
+ var url = '';
+ if (id.match(/\d\d\/.*/)) {
+ url = 'http://thebookofshaders.com/' + id;
+ } else {
+ url = 'http://thebookofshaders.com/log/' + id;
+ }
+
+ xhr.send(JSON.stringify({
+ title: title,
+ author_name: author,
+ is_public: false,
+ format: 'openframe-glslviewer',
+ url: url + '.frag',
+ thumb_url: url + '.png'
+ }));
+}
+
+},{"babel-runtime/helpers/class-call-check":2}],17:[function(_dereq_,module,exports){
+'use strict';
+
+var _createClass = _dereq_('babel-runtime/helpers/create-class')['default'];
+
+var _classCallCheck = _dereq_('babel-runtime/helpers/class-call-check')['default'];
+
+var _interopRequireDefault = _dereq_('babel-runtime/helpers/interop-require-default')['default'];
+
+Object.defineProperty(exports, '__esModule', {
+ value: true
+});
+
+var _xhr = _dereq_('xhr');
+
+var _xhr2 = _interopRequireDefault(_xhr);
+
+var _glslCanvas = _dereq_('glslCanvas');
+
+var _glslCanvas2 = _interopRequireDefault(_glslCanvas);
+
+var _addonsOpenFrameIcon = _dereq_('../addons/openFrameIcon');
+
+var _addonsOpenFrameIcon2 = _interopRequireDefault(_addonsOpenFrameIcon);
+
+var GalleryItem = (function () {
+ function GalleryItem(id, main, options) {
+ var _this = this;
+
+ _classCallCheck(this, GalleryItem);
+
+ this.id = id;
+ this.main = main;
+ this.options = options;
+
+ // Construct Item
+ this.el = document.createElement('div');
+ this.el.setAttribute('class', 'glslGallery_item');
+
+ this.link = document.createElement('a');
+ this.link.setAttribute('target', '_blank');
+
+ this.img = document.createElement('img');
+ this.img.setAttribute('class', 'glslGallery_thumb');
+
+ this.credits = document.createElement('div');
+ this.credits.setAttribute('class', 'glslGallery_credits');
+ this.credits.style.visibility = 'hidden';
+
+ if (this.id.match(/\d\d\/.*/)) {
+ this.link.setAttribute('href', 'http://thebookofshaders.com/edit.html#' + this.id + '.frag');
+ this.img.src = 'http://thebookofshaders.com/' + this.id + '.png';
+ } else {
+ this.link.setAttribute('href', 'http://' + this.options.clickRun + '.thebookofshaders.com/?log=' + this.id);
+ this.img.src = 'http://thebookofshaders.com/log/' + this.id + '.png';
+ }
+
+ this.link.appendChild(this.img);
+ this.el.appendChild(this.link);
+ this.el.appendChild(this.credits);
+ this.main.container.appendChild(this.el);
+
+ // Add events
+ if (this.options.hoverPreview) {
+ this.el.addEventListener('mouseenter', function () {
+ onEnter(_this);
+ });
+ this.el.addEventListener('mouseleave', function () {
+ onLeave(_this);
+ });
+ }
+
+ if (this.options.openFrameIcon) {
+ this.openFrameIcon = new _addonsOpenFrameIcon2['default'](this);
+ }
+
+ this.init();
+ }
+
+ _createClass(GalleryItem, [{
+ key: 'init',
+ value: function init() {
+ var _this2 = this;
+
+ if (!this.source || this.source === '') {
+ var url;
+
+ (function () {
+ url = '';
+
+ if (_this2.id.match(/\d\d\/.*/)) {
+ url = 'http://thebookofshaders.com/' + _this2.id + '.frag';
+ } else {
+ url = 'http://thebookofshaders.com/log/' + _this2.id + '.frag';
+ }
+ var item = _this2;
+ _xhr2['default'].get(url, function (error, res, body) {
+ if (error) {
+ console.error('Error downloading ', error);
+ return;
+ }
+ item.setCode(body);
+ });
+ })();
+ }
+ }
+ }, {
+ key: 'load',
+ value: function load(code) {
+ this.setCode(code);
+ window.glslGallery_canvas.load(code);
+ window.glslGallery_canvas.canvas.style.height = this.img.offsetHeight + 'px';
+ this.link.appendChild(window.glslGallery_canvas.canvas);
+ }
+ }, {
+ key: 'setCode',
+ value: function setCode(code) {
+ this.source = code;
+
+ if (!this.author && this.options.showAuthor) {
+ this.author = this.getAuthor();
+ if (this.author !== 'unknown') {
+ var authorEl = document.createElement('p');
+ authorEl.setAttribute('class', 'glslGallery_label glslGallery_author');
+ authorEl.innerHTML = this.author;
+ this.credits.appendChild(authorEl);
+ this.credits.style.visibility = 'visible';
+ }
+ }
+
+ if (!this.title && this.options.showTitle) {
+ this.title = this.getTitle();
+ if (this.title !== 'unknown') {
+ var titleEl = document.createElement('p');
+ titleEl.setAttribute('class', 'glslGallery_label glslGallery_title');
+ titleEl.innerHTML = this.title;
+ this.credits.appendChild(titleEl);
+ this.credits.style.visibility = 'visible';
+ }
+ }
+ }
+ }, {
+ key: 'getCode',
+ value: function getCode() {
+ return this.source;
+ }
+ }, {
+ key: 'getTitle',
+ value: function getTitle() {
+ var result = this.source.match(/\/\/\s*[T|t]itle\s*:\s*([\w|\s|\@|\(|\)|\-|\_]*)/i);
+ if (result && !(result[1] === ' ' || result[1] === '')) {
+ return result[1].replace(/(\r\n|\n|\r)/gm, '');
+ } else {
+ return 'unknown';
+ }
+ }
+ }, {
+ key: 'getAuthor',
+ value: function getAuthor() {
+ var result = this.source.match(/\/\/\s*[A|a]uthor\s*[\:]?\s*([\w|\s|\@|\(|\)|\-|\_]*)/i);
+ if (result && !(result[1] === ' ' || result[1] === '')) {
+ return result[1].replace(/(\r\n|\n|\r)/gm, '');
+ } else {
+ return 'unknown';
+ }
+ }
+ }]);
+
+ return GalleryItem;
+})();
+
+exports['default'] = GalleryItem;
+
+function initCanvas() {
+ if (!window.glslGallery_canvas) {
+ var canvas = document.createElement('canvas');
+ canvas.setAttribute('class', 'glslGallery_canvas');
+ canvas.style.width = '250px';
+ canvas.style.height = '250px';
+ canvas.width = '250px';
+ canvas.height = '250px';
+ window.glslGallery_canvas = new _glslCanvas2['default'](canvas);
+ }
+}
+
+function onEnter(item) {
+ initCanvas();
+
+ if (item.getCode()) {
+ item.load(item.getCode());
+ } else {
+ var url = '';
+ if (item.id.match(/\d\d\/.*/)) {
+ url = 'http://thebookofshaders.com/' + item.id + '.frag';
+ } else {
+ url = 'http://thebookofshaders.com/log/' + item.id + '.frag';
+ }
+
+ _xhr2['default'].get(url, function (error, res, body) {
+ if (error) {
+ console.error('Error downloading ', error);
+ return;
+ }
+ item.load(body);
+ });
+ }
+}
+
+function onLeave(item) {
+ initCanvas();
+
+ if (item.el.getElementsByClassName('glslGallery_canvas') > 0) {
+ // Remove glslCanvas instance from item
+ item.el.removeChild(window.glslGallery_canvas.canvas);
+ }
+}
+module.exports = exports['default'];
+
+},{"../addons/openFrameIcon":16,"babel-runtime/helpers/class-call-check":2,"babel-runtime/helpers/create-class":3,"babel-runtime/helpers/interop-require-default":4,"glslCanvas":9,"xhr":13}],18:[function(_dereq_,module,exports){
+/*
+The MIT License (MIT)
+
+Copyright (c) 2016 Patricio Gonzalez Vivo ( http://www.patriciogonzalezvivo.com )
+
+Permission is hereby granted, free of charge, to any person obtaining a copy of
+this software and associated documentation files (the 'Software'), to deal in
+the Software without restriction, including without limitation the rights to
+use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
+the Software, and to permit persons to whom the Software is furnished to do so,
+subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
+FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
+COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
+IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
+CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+*/
+
+'use strict';
+
+var _createClass = _dereq_('babel-runtime/helpers/create-class')['default'];
+
+var _classCallCheck = _dereq_('babel-runtime/helpers/class-call-check')['default'];
+
+var _interopRequireDefault = _dereq_('babel-runtime/helpers/interop-require-default')['default'];
+
+Object.defineProperty(exports, '__esModule', {
+ value: true
+});
+
+var _appCoreGalleryItem = _dereq_('app/core/GalleryItem');
+
+var _appCoreGalleryItem2 = _interopRequireDefault(_appCoreGalleryItem);
+
+var GlslGallery = (function () {
+ function GlslGallery(selector, options) {
+ _classCallCheck(this, GlslGallery);
+
+ if (typeof selector === 'object' && selector.nodeType && selector.nodeType === 1) {
+ this.container = selector;
+ } else if (typeof selector === 'string') {
+ this.container = document.querySelector(selector);
+ } else {
+ console.log('Error, type ' + typeof selector + ' of ' + selector + ' is unknown');
+ return;
+ }
+
+ this.options = options || {};
+
+ if (!this.options.showAuthor) {
+ this.options.showAuthor = true;
+ }
+
+ if (!this.options.showTitle) {
+ this.options.showTitle = true;
+ }
+
+ if (!this.options.hoverPreview) {
+ this.options.hoverPreview = true;
+ }
+
+ if (!this.options.openFrameIcon) {
+ this.options.openFrameIcon = true;
+ }
+
+ if (!this.options.clickRun) {
+ this.options.clickRun = 'player';
+ }
+
+ this.items = [];
+
+ if (selector.hasAttribute('data-properties')) {
+ var prop = selector.getAttribute('data-properties').split(',');
+ for (var i in prop) {
+ var values = prop[i].split(':');
+ if (values.length === 1) {
+ this.options[values[0]] = true;
+ } else if (values.length === 2) {
+ this.options[values[0]] = values[1] === 'true' || values[1] === 'false' ? values[1] === 'true' : values[1];
+ }
+ }
+ }
+
+ if (selector.hasAttribute('data')) {
+ var data = selector.getAttribute('data').split(',');
+ for (var i in data) {
+ this.items.push(new _appCoreGalleryItem2['default'](data[i], this, this.options));
+ }
+ }
+
+ return this;
+ }
+
+ _createClass(GlslGallery, [{
+ key: 'version',
+ value: function version() {
+ return '0.0.1';
+ }
+ }]);
+
+ return GlslGallery;
+})();
+
+exports['default'] = GlslGallery;
+
+function glslGalleryLoadAll() {
+ if (!window.GlslGallery) {
+ window.GlslGallery = GlslGallery;
+ }
+
+ var list = document.getElementsByClassName('glslGallery');
+ if (list.length > 0) {
+ window.glslGalleries = [];
+ for (var i = 0; i < list.length; i++) {
+ var gallery = new GlslGallery(list[i]);
+ window.glslGalleries.push(gallery);
+ }
+ }
+}
+
+
+
+
+var GlslChapterGallery = (function () {
+ function GlslChapterGallery(selector, options) {
+ _classCallCheck(this, GlslChapterGallery);
+
+ if (typeof selector === 'object' && selector.nodeType && selector.nodeType === 1) {
+ this.container = selector;
+ } else if (typeof selector === 'string') {
+ this.container = document.querySelector(selector);
+ } else {
+ console.log('Error, type ' + typeof selector + ' of ' + selector + ' is unknown');
+ return;
+ }
+
+ this.options = options || {};
+
+ if (!this.options.showAuthor) {
+ this.options.showAuthor = true;
+ }
+
+ if (!this.options.showTitle) {
+ this.options.showTitle = true;
+ }
+
+ if (!this.options.hoverPreview) {
+ this.options.hoverPreview = true;
+ }
+
+ if (!this.options.openFrameIcon) {
+ this.options.openFrameIcon = true;
+ }
+
+ if (!this.options.clickRun) {
+ this.options.clickRun = 'player';
+ }
+
+ this.items = [];
+
+ if (selector.hasAttribute('data-properties')) {
+ var prop = selector.getAttribute('data-properties').split(',');
+ for (var i in prop) {
+ var values = prop[i].split(':');
+ if (values.length === 1) {
+ this.options[values[0]] = true;
+ } else if (values.length === 2) {
+ this.options[values[0]] = values[1] === 'true' || values[1] === 'false' ? values[1] === 'true' : values[1];
+ }
+ }
+ }
+ if (selector.hasAttribute('data')) {
+ var data = selector.getAttribute('data').split(',');
+ var list = shaderList[data[0]];
+ var numDisplay = (data[1]) ? Math.min(list.length, data[1]) : list.length;
+
+ for (var i = 0; i < numDisplay; i ++) {
+ this.items.push(new _appCoreGalleryItem2['default'](list[i], this, this.options));
+ }
+ }
+
+ return this;
+ }
+
+ _createClass(GlslChapterGallery, [{
+ key: 'version',
+ value: function version() {
+ return '0.0.1';
+ }
+ }]);
+
+ return GlslChapterGallery;
+})();
+
+function loadChapterGalleries() {
+ if (!window.GlslGallery) {
+ window.GlslGallery = GlslGallery;
+ }
+
+ var list = document.getElementsByClassName('glslChapterGallery');
+ if (list.length > 0) {
+ window.glslGalleries = [];
+ for (var i = 0; i < list.length; i++) {
+ var gallery = new GlslChapterGallery(list[i]);
+ window.glslGalleries.push(gallery);
+ }
+ }
+}
+
+window.addEventListener("load", function () {
+ loadChapterGalleries();
+});
+module.exports = exports['default'];
+
+},{"app/core/GalleryItem":17,"babel-runtime/helpers/class-call-check":2,"babel-runtime/helpers/create-class":3,"babel-runtime/helpers/interop-require-default":4}]},{},[18])(18)
+});
+//# sourceMappingURL=data:application/json;charset:utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIm5vZGVfbW9kdWxlcy9icm93c2VyLXBhY2svX3ByZWx1ZGUuanMiLCJub2RlX21vZHVsZXMvYmFiZWwtcnVudGltZS9jb3JlLWpzL29iamVjdC9kZWZpbmUtcHJvcGVydHkuanMiLCJub2RlX21vZHVsZXMvYmFiZWwtcnVudGltZS9oZWxwZXJzL2NsYXNzLWNhbGwtY2hlY2suanMiLCJub2RlX21vZHVsZXMvYmFiZWwtcnVudGltZS9oZWxwZXJzL2NyZWF0ZS1jbGFzcy5qcyIsIm5vZGVfbW9kdWxlcy9iYWJlbC1ydW50aW1lL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ICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIC8vIDwtIHN0YXRlXG4gICAgICBkOiBmYWxzZSwgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgLy8gPC0gZG9uZVxuICAgICAgdjogdW5kZWZpbmVkLCAgICAgICAgICAgICAgICAgICAgICAgICAgIC8vIDwtIHZhbHVlXG4gICAgICBoOiBmYWxzZSwgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgLy8gPC0gaGFuZGxlZCByZWplY3Rpb25cbiAgICAgIG46IGZhbHNlICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAvLyA8LSBub3RpZnlcbiAgICB9O1xuICAgIHRyeSB7XG4gICAgICBleGVjdXRvcihjdHgoJHJlc29sdmUsIHJlY29yZCwgMSksIGN0eCgkcmVqZWN0LCByZWNvcmQsIDEpKTtcbiAgICB9IGNhdGNoKGVycil7XG4gICAgICAkcmVqZWN0LmNhbGwocmVjb3JkLCBlcnIpO1xuICAgIH1cbiAgfTtcbiAgcmVxdWlyZSgnLi8kLnJlZGVmaW5lLWFsbCcpKFAucHJvdG90eXBlLCB7XG4gICAgLy8gMjUuNC41LjMgUHJvbWlzZS5wcm90b3R5cGUudGhlbihvbkZ1bGZpbGxlZCwgb25SZWplY3RlZClcbiAgICB0aGVuOiBmdW5jdGlvbiB0aGVuKG9uRnVsZmlsbGVkLCBvblJlamVjdGVkKXtcbiAgICAgIHZhciByZWFjdGlvbiA9IG5ldyBQcm9taXNlQ2FwYWJpbGl0eShzcGVjaWVzQ29uc3RydWN0b3IodGhpcywgUCkpXG4gICAgICAgICwgcHJvbWlzZSAgPSByZWFjdGlvbi5wcm9taXNlXG4gICAgICAgICwgcmVjb3JkICAgPSB0aGlzLl9kO1xuICAgICAgcmVhY3Rpb24ub2sgICA9IHR5cGVvZiBvbkZ1bGZpbGxlZCA9PSAnZnVuY3Rpb24nID8gb25GdWxmaWxsZWQgOiB0cnVlO1xuICAgICAgcmVhY3Rpb24uZmFpbCA9I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HRvIHJlc3BvbnNlVGV4dFxuICAgICAgICB2YXIgYm9keSA9IHVuZGVmaW5lZFxuXG4gICAgICAgIGlmICh4aHIucmVzcG9uc2UpIHtcbiAgICAgICAgICAgIGJvZHkgPSB4aHIucmVzcG9uc2VcbiAgICAgICAgfSBlbHNlIGlmICh4aHIucmVzcG9uc2VUeXBlID09PSBcInRleHRcIiB8fCAheGhyLnJlc3BvbnNlVHlwZSkge1xuICAgICAgICAgICAgYm9keSA9IHhoci5yZXNwb25zZVRleHQgfHwgeGhyLnJlc3BvbnNlWE1MXG4gICAgICAgIH1cblxuICAgICAgICBpZiAoaXNKc29uKSB7XG4gICAgICAgICAgICB0cnkge1xuICAgICAgICAgICAgICAgIGJvZHkgPSBKU09OLnBhcnNlKGJvZHkpXG4gICAgICAgICAgICB9IGNhdGNoIChlKSB7fVxuICAgICAgICB9XG5cbiAgICAgICAgcmV0dXJuIGJvZHlcbiAgICB9XG5cbiAgICB2YXIgZmFpbHVyZVJlc3BvbnNlID0ge1xuICAgICAgICAgICAgICAgIGJvZHk6IHVuZGVmaW5lZCxcbiAgICAgICAgICAgICAgICBoZWFkZXJzOiB7fSxcbiAgICAgICAgICAgICAgICBzdGF0dXNDb2RlOiAwLFxuICAgICAgICAgICAgICAgIG1ldGhvZDogbWV0aG9kLFxuICAgICAgICAgICAgICAgIHVybDogdXJpLFxuICAgICAgICAgICAgICAgIHJhd1JlcXVlc3Q6IHhoclxuICAgICAgICAgICAgfVxuXG4gICAgZnVuY3Rpb24gZXJyb3JGdW5jKGV2dCkge1xuICAgICAgICBjbGVhclRpbWVvdXQodGltZW91dFRpbWVyKVxuICAgICAgICBpZighKGV2dCBpbnN0YW5jZW9mIEVycm9yKSl7XG4gICAgICAgICAgICBldnQgPSBuZXcgRXJyb3IoXCJcIiArIChldnQgfHwgXCJVbmtub3duIFhNTEh0dHBSZXF1ZXN0IEVycm9yXCIpIClcbiAgICAgICAgfVxuICAgICAgICBldnQuc3RhdHVzQ29kZSA9IDB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gICAgc2V0VXJsKHVybCwgb3B0aW9ucyA9IHt9KSB7XG4gICAgICAgIGlmICghdGhpcy52YWxpZCkge1xuICAgICAgICAgICAgcmV0dXJuO1xuICAgICAgICB9XG5cbiAgICAgICAgdGhpcy51cmwgPSB1cmw7IC8vIHNhdmUgVVJMIHJlZmVyZW5jZSAod2lsbCBiZSBvdmVyd3JpdHRlbiB3aGVuIGVsZW1lbnQgaXMgbG9hZGVkIGJlbG93KVxuICAgICAgICB0aGlzLnNvdXJjZSA9IHRoaXMudXJsO1xuICAgICAgICB0aGlzLnNvdXJjZVR5cGUgPSAndXJsJztcblxuICAgICAgICB0aGlzLmxvYWRpbmcgPSBuZXcgUHJvbWlzZSgocmVzb2x2ZSwgcmVqZWN0KSA9PiB7XG4gICAgICAgICAgICBsZXQgaW1hZ2UgPSBuZXcgSW1hZ2UoKTtcbiAgICAgICAgICAgIGltYWdlLm9ubG9hZCA9ICgpID0+IHtcbiAgICAgICAgICAgICAgICB0cnkge1xuICAgICAgICAgICAgICAgICAgICB0aGlzLnNldEVsZW1lbnQoaW1hZ2UsIG9wdGlvbnMpO1xuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICBjYXRjaCAoZSkge1xuICAgICAgICAgICAgICAgICAgICBjb25zb2xlLmxvZyhgVGV4dHVyZSAnJHt0aGlzLm5hbWV9JzogZmFpbGVkIHRvIGxvYWQgdXJsOiAnJHt0aGlzLnNvdXJjZX0nYCwgZSwgb3B0aW9ucyk7XG4gICAgICAgICAgICAgICAgfVxuXG4gICAgICAgICAgICAgICAgcmVzb2x2ZSh0aGlzKTtcbiAgICAgICAgICAgIH07XG4gICAgICAgICAgICBpbWFnZS5vbmVycm9yID0gZSA9PiB7XG4gICAgICAgICAgICAgICAgLy8gV2FybiBhbmQgcmVzb2x2ZSBvbiBlcnJvclxuICAgICAgICAgICAgICAgIGNvbnNvbGUubG9nKGBUZXh0dXJlICcke3RoaXMubmFtZX0nOiBmYWlsZWQgdG8gbG9hZC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AgIHR5cGU6ICdmbG9hdCcsXG4gICAgICAgICAgICAgICAgbWV0aG9kOiAnMWYnLFxuICAgICAgICAgICAgICAgIG5hbWUsXG4gICAgICAgICAgICAgICAgdmFsdWU6IHVuaWZvcm1cbiAgICAgICAgICAgIH0pO1xuICAgICAgICB9XG4gICAgICAgIC8vIEFycmF5OiB2ZWN0b3IsIGFycmF5IG9mIGZsb2F0cywgYXJyYXkgb2YgdGV4dHVyZXMsIG9yIGFycmF5IG9mIHN0cnVjdHNcbiAgICAgICAgZWxzZSBpZiAoQXJyYXkuaXNBcnJheSh1bmlmb3JtKSkge1xuICAgICAgICAgICAgLy8gTnVtZXJpYyB2YWx1ZXNcbiAgICAgICAgICAgIGlmICh0eXBlb2YgdW5pZm9ybVswXSA9PT0gJ251bWJlcicpIHtcbiAgICAgICAgICAgICAgICAvLyBmbG9hdCB2ZWN0b3JzICh2ZWMyLCB2ZWMzLCB2ZWM0KVxuICAgICAgICAgICAgICAgIGlmICh1bmlmb3JtLmxlbmd0aCA9PT0gMSkge1xuICAgICAgICAgICAgICAgICAgICBwYXJzZWQucHVzaCh7XG4gICAgICAgICAgICAgICAgICAgICAgICB0eXBlOiAnZmxvYXQnLFxuICAgICAgICAgICAgICAgICAgICAgICAgbWV0aG9kOiAnMWYnLFxuICAgICAgICAgICAgICAgICAgICAgICAgbmFtZSxcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhbHVlOiB1bmlmb3JtXG4gICAgICAgICAgICAgICAgICAgIH0pO1xuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICAvLyBmbG9hdCB2ZWN0b3JzICh2ZWMyLCB2ZWMzLCB2ZWM0KVxuICAgICAgICAgICAgICAgIGVsc2UgaWYgKHVuaWZvcm0ubGVuZ3RoID49IDIgJiYgdW5pZm9ybS5sZW5ndGggPD0gNCkge1xuICAgICAgICAgICAgICAgICAgICBwYXJzZWQucHVzaCh7XG4gICAgICAgICAgICAgICAgICAgICAgICB0eXBlOiAndmVjJyArIHVuaWZvcm0ubGVuZ3RoLFxuICAgICAgICAgICAgICAgICAgICAgICAgbWV0aG9kOiB1bmlmb3JtLmxlbmd0aCArICdmdicsXG4gICAgICAgICAgICAgICAgICAgICAgICBuYW1lLFxuICAgICAgICAgICAgICAgICAgICAgICAgdmFsdWU6IHVuaWZvcm1cbiAgICAgICAgICAgICAgICAgICAgfSk7XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIC8vIGZsb2F0IGFycmF5XG4gICAgICAgICAgICAgICAgZWxzZSBpZiAodW5pZm9ybS5sZW5ndGggPiA0KSB7XG4gICAgICAgICAgICAgICAgICAgIHBhcnNlZC5wdXNoKHtcbiAgICAgICAgICAgICAgICAgICAgICAgIHR5cGU6ICdmbG9hdFtdJyxcbiAgICAgICAgICAgICAgICAgICAgICAgIG1ldGhvZDogJzFmdicsXG4gICAgICAgICAgICAgICAgICAgICAgICBuYW1lOiBuYW1lICsgJ1swXScsXG4gICAgICAgICAgICAgICAgICAgICAgICB2YWx1ZTogdW5pZm9ybVxuICAgICAgICAgICAgICAgICAgICB9KTtcbiAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgLy8gVE9ETzogYXNzdW1lIG1hdHJpeCBmb3IgKHR5cGVvZiA9PSBGbG9hdDMyQXJyYXkgJiYgbGVuZ3RoID09IDE2KT9cbiAgICAgICAgICAgIH1cbiAgICAgICAgICAgIC8vIEFycmF5IG9mIHRleHR1cmVzXG4gICAgICAgICAgICBlbHNlIGlmICh0eXBlb2YgdW5pZm9ybVswXSA9PT0gJ3N0cmluZycpIHtcbiAgICAgICAgICAgICAgICBwYXJzZWQucHVzaCh7XG4gICAgICAgICAgICAgICAgICAgIHR5cGU6ICdzYW1wbGVyMkQnLFxuICAgICAgICAgICAgICAgICAgICBtZXRob2Q6ICcxaScsXG4gICAgICAgICAgICAgICAgICAgIG5hbWU6IG5hbWUsXG4gICAgICAgICAgICAgICAgICAgIHZhbHVlOiB1bmlmb3JtXG4gICAgICAgICAgICAgICAgfSk7XG4gICAgICAgICAgICB9XG4gICAgICAgICAgICAvLyBBcnJheSBvZiBhcnJheXMgLSBidXQgb25seSBhcnJheXMgb2YgdmVjdG9ycyBhcmUgYWxsb3dlZCBpbiB0aGlzIGNhc2VcbiAgICAgICAgICAgIGVsc2UgaWYgKEFycmF5LmlzQXJyYXkodW5pZm9ybVswXSkgJiYgdHlwZW9mIHVuaWZvcm1bMF1bMF0gPT09ICdudW1iZXInKSB7XG4gICAgICAgICAgICAgICAgLy8gZmxvYXQgdmVjdG9ycyAodmVjMiwgdmVjMywgdmVjNClcbiAgICAgICAgICAgICAgICBpZiAodW5pZm9ybVswXS5sZW5ndGggPj0gMiAmJiB1bmlmb3JtWzBdLmxlbmd0aCA8PSA0KSB7XG4gICAgICAgICAgICAgICAgICAgIC8vIFNldCBlYWNoIHZlY3RvciBpbiB0aGUgYXJyYXlcbiAgICAgICAgICAgICAgICAgICAgZm9yICh1ID0gMDsgdSA8IHVuaWZvcm0ubGVuZ3RoOyB1KyspIHtcbiAgICAgICAgICAgICAgICAgICAgICAgIHBhcnNlZC5wdXNoKHtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB0eXBlOiAndmVjJyArIHVuaWZvcm1bMF0ubGVuZ3RoLFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIG1ldGhvZDogdW5pZm9ybVt1XS5sZW5ndGggKyAnZnYnLFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIG5hbWU6IG5hbWUgKyAnWycgKyB1ICsgJ10nLFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHZhbHVlOiB1bmlmb3JtW3VdXG4gICAgICAgICAgICAgICAgICAgICAgICB9KTtcbiAgICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICAvLyBlbHNlIGVycm9yP1xuICAgICAgICAgICAgfVxuICAgICAgICAgICAgLy8gQXJyYXkgb2Ygc3RydWN0dXJlc1xuICAgICAgICAgICAgZWxzZSBpZiAodHlwZW9mIHVuaWZvcm1bMF0gPT09ICdvYmplY3QnKSB7XG4gICAgICAgICAgICAgICAgZm9yICh1ID0gMDsgdSA8IHVuaWZvcm0ubGVuZ3RoOyB1KyspIHtcbiAgICAgICAgICAgICAgICAgICAgLy8gU2V0IGVhY2ggc3RydWN0IGluIHRoZSBhcnJheVxuICAgICAgICAgICAgICAgICAgICBwYXJzZWQucHVzaCguLi5wYXJzZVVuaWZvcm1zKHVuaWZvcm1bdV0sIG5hbWUgKyAnWycgKyB1ICsgJ10nKSk7XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgfVxuICAgICAgICB9XG4gICAgICAgIC8vIEJvb2xlYW5cbiAgICAgICAgZWxzZSBpZiAodHlwZW9mIHVuaWZvcm0gPT09ICdib29sZWFuJykge1xuICAgICAgICAgICAgcGFyc2VkLnB1c2goe1xuICAgICAgICAgICAgICAgIHR5cGU6ICdib29sJyxcbiAgICAgICAgICAgICAgICBtZXRob2Q6ICcxaScsXG4gICAgICAgICAgICAgICAgbmFtZSxcbiAgICAgICAgICAgICAgICB2YWx1ZTogdW5pZm9ybVxuICAgICAgICAgICAgfSk7XG4gICAgICAgIH1cbiAgICAgICAgLy8gVGV4dHVyZVxuICAgICAgICBlbHNlIGlmICh0eXBlb2YgdW5pZm9ybSA9PT0gJ3N0cmluZycpIHtcbiAgICAgICAgICAgIHBhcnNlZC5wdXNoKHtcbiAgICAgICAgICAgICAgICB0eXBlOiAnc2FtcGxlcjJEJyxcbiAgICAgICAgICAgICAgICBtZXRob2Q6ICcxaScsXG4gICAgICAgICAgICAgICAgbmFtZSxcbiAgICAgICAgICAgICAgICB2YWx1ZTogdW5pZm9ybVxuICAgICAgICAgICAgfSk7XG4gICAgICAgIH1cbiAgICAgICAgLy8gU3RydWN0dXJlXG4gICAgICAgIGVsc2UgaWYgKHR5cGVvZiB1bmlmb3JtID09PSAnb2JqZWN0Jykge1xuICAgICAgICAgICAgLy8gU2V0I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pIHtcbiAgICAgICAgICAgIGZvciAodmFyIGxpc3RlbmVyIG9mIGxpc3RlbmVycykge1xuICAgICAgICAgICAgICAgIGlmICh0eXBlb2YgbGlzdGVuZXJbZXZlbnRdID09PSAnZnVuY3Rpb24nKSB7XG4gICAgICAgICAgICAgICAgICAgIGxpc3RlbmVyW2V2ZW50XSguLi5kYXRhKTtcbiAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICB9XG4gICAgICAgIH1cbiAgICB9KTtcbn1cbiIsImV4cG9ydCBmdW5jdGlvbiBzdWJzY3JpYmVNaXhpbiAodGFyZ2V0KSB7XG4gICAgdmFyIGxpc3RlbmVycyA9IG5ldyBTZXQoKTtcblxuICAgIHJldHVybiBPYmplY3QuYXNzaWduKHRhcmdldCwge1xuXG4gICAgICAgIG9uKHR5cGUsIGYpIHtcbiAgICAgICAgICAgIGxldCBsaXN0ZW5lciA9IHt9O1xuICAgICAgICAgICAgbGlzdGVuZXJbdHlwZV0gPSBmO1xuICAgICAgICAgICAgbGlzdGVuZXJzLmFkZChsaXN0ZW5lcik7XG4gICAgICAgIH0sXG5cbiAgICAgICAgb2ZmKHR5cGUsIGYpIHtcbiAgICAgICAgICAgIGlmIChmKSB7XG4gICAgICAgICAgICAgICAgbGV0IGxpc3RlbmVyID0ge307XG4gICAgICAgICAgICAgICAgbGlzdGVuZXJbdHlwZV0gPSBmO1xuICAgICAgICAgICAgICAgIGxpc3RlbmVycy5kZWxldGUobGlzdGVuZXIpO1xuICAgICAgICAgICAgfVxuICAgICAgICAgICAgZWxzZSB7XG4gICAgICAgICAgICAgICAgZm9yIChsZXQgaXRlbSBvZiBsaXN0ZW5lcnMpIHtcbiAgICAgICAgICAgICAgICAgICAgZm9yIChsZXQga2V5IG9mIE9iamVjdC5rZXlzKGl0ZW0pKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICBpZiAoa2V5ID09PSB0eXBlKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgbGlzdGVuZXJzLmRlbGV0ZShpdGVtKTtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm47XG4gICAgICAgICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICB9XG4gICAgICAgIH0sXG5cbiAgICAgICAgbGlzdFN1YnNjcmlwdGlvbnMoKSB7XG4gICAgICAgICAgICBmb3IgKGxldCBpdGVtIG9mIGxpc3RlbmVycykge1xuICAgICAgICAgICAgICAgIGNvbnNvbGUubG9nKGl0ZW0pO1xuICAgICAgICAgICAgfVxuICAgICAgICB9LFxuXG4gICAgICAgIHN1YnNjcmliZShsaXN0ZW5lcikge1xuICAgICAgICAgICAgbGlzdGVuZXJzLmFkZChsaXN0ZW5lcik7XG4gICAgICAgIH0sXG5cbiAgICAgICAgdW5zdWJzY3JpYmUobGlzdGVuZXIpIHtcbiAgICAgICAgICAgIGxpc3RlbmVycy5kZWxldGUobGlzdGVuZXIpO1xuICAgICAgICB9LFxuXG4gICAgICAgIHVuc3Vic2NyaWJlQWxsKCkge1xuICAgICAgICAgICAgbGlzdGVuZXJzLmNsZWFyKCk7XG4gICAgICAgIH0sXG5cbiAgICAgICAgdHJpZ2dlcihldmVudCwgLi4uZGF0YSkge1xuICAgICAgICAgICAgZm9yICh2YXIgbGlzdGVuZXIgb2YgbGlzdGVuZXJzKSB7XG4gICAgICAgICAgICAgICAgaWYgKHR5cGVvZiBsaXN0ZW5lcltldmVudF0gPT09ICdmdW5jdGlvbicpIHtcbiAgICAgICAgICAgICAgICAgICAgbGlzdGVuZXJbZXZlbnRdKC4uLmRhdGEpO1xuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgIH1cbiAgICAgICAgfVxuICAgIH0pO1xufVxuIiwibW9kdWxlLmV4cG9ydHMgPSBpc0Z1bmN0aW9uXG5cbnZhciB0b1N0cmluZyA9IE9iamVjdC5wcm90b3R5cGUudG9TdHJpbmdcblxuZnVuY3Rpb24ga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IHRvIHJlc3BvbnNlVGV4dFxuICAgICAgICB2YXIgYm9keSA9IHVuZGVmaW5lZFxuXG4gICAgICAgIGlmICh4aHIucmVzcG9uc2UpIHtcbiAgICAgICAgICAgIGJvZHkgPSB4aHIucmVzcG9uc2VcbiAgICAgICAgfSBlbHNlIGlmICh4aHIucmVzcG9uc2VUeXBlID09PSBcInRleHRcIiB8fCAheGhyLnJlc3BvbnNlVHlwZSkge1xuICAgICAgICAgICAgYm9keSA9IHhoci5yZXNwb25zZVRleHQgfHwgeGhyLnJlc3BvbnNlWE1MXG4gICAgICAgIH1cblxuICAgICAgICBpZiAoaXNKc29uKSB7XG4gICAgICAgICAgICB0cnkge1xuICAgICAgICAgICAgICAgIGJvZHkgPSBKU09OLnBhcnNlKGJvZHkpXG4gICAgICAgICAgICB9IGNhdGNoIChlKSB7fVxuICAgICAgICB9XG5cbiAgICAgICAgcmV0dXJuIGJvZHlcbiAgICB9XG5cbiAgICB2YXIgZmFpbHVyZVJlc3BvbnNlID0ge1xuICAgICAgICAgICAgICAgIGJvZHk6IHVuZGVmaW5lZCxcbiAgICAgICAgICAgICAgICBoZWFkZXJzOiB7fSxcbiAgICAgICAgICAgICAgICBzdGF0dXNDb2RlOiAwLFxuICAgICAgICAgICAgICAgIG1ldGhvZDogbWV0aG9kLFxuICAgICAgICAgICAgICAgIHVybDogdXJpLFxuICAgICAgICAgICAgICAgIHJhd1JlcXVlc3Q6IHhoclxuICAgICAgICAgICAgfVxuXG4gICAgZnVuY3Rpb24gZXJyb3JGdW5jKGV2dCkge1xuICAgICAgICBjbGVhclRpbWVvdXQodGltZW91dFRpbWVyKVxuICAgICAgICBpZighKGV2dCBpbnN0YW5jZW9mIEVycm9yKSl7XG4gICAgICAgICAgICBldnQgPSBuZXcgRXJyb3IoXCJcIiArIChldnQgfHwgXCJVbmtub3duIFhNTEh0dHBSZXF1ZXN0IEVycm9yXCIpIClcbiAgICAgICAgfVxuICAgICAgICBldnQuc3RhdHVzQ29kZSA9ID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llczpcbiAgICB4aHIud2l0aENyZWRlbnRpYWxzID0gdHJ1ZTtcbiAgICB4aHIub25sb2FkID0gKGV2ZW50KSA9PiB7XG4gICAgICAgIGlmIChldmVudC5jdXJyZW50VGFyZ2V0LnN0YXR1cyA9PT0gNDA0KSB7XG4gICAgICAgICAgICB3aW5kb3cub3BlbignaHR0cDovL29wZW5mcmFtZS5pby9sb2dpbi1wb3B1cCcsICdsb2dpbicsICd3aWR0aD01MDAsaGVpZ2h0PTYwMCcpO1xuICAgICAgICAgICAgbGV0IHN1Y2Nlc3NMaXN0ZW5lciA9IGZ1bmN0aW9uKGUpIHtcbiAgICAgICAgICAgICAgICBpZiAoZS5kYXRhID09PSAnc3VjY2VzcycpIHtcbiAgICAgICAgICAgICAgICAgICAgY3JlYXRlT3BlbkZyYW1lQXJ0d29yayhpdGVtLCBjYWxsYmFjayk7XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIHdpbmRvdy5yZW1vdmVFdmVudExpc3RlbmVyKCdtZXNzYWdlJywgc3VjY2Vzc0xpc3RlbmVyKTtcbiAgICAgICAgICAgIH07XG4gICAgICAgICAgICB3aW5kb3cuYWRkRXZlbnRMaXN0ZW5lcignbWVzc2FnZScsIHN1Y2Nlc3NMaXN0ZW5lciwgZmFsc2UpO1xuICAgICAgICB9XG4gICAgICAgIGVsc2UgaWYgKGV2ZW50LmN1cnJlbnRUYXJnZXQuc3RhdHVzID09PSAyMDApIHtcbiAgICAgICAgICAgIGNhbGxiYWNrKHRydWUpO1xuICAgICAgICB9XG4gICAgICAgIGVsc2Uge1xuICAgICAgICAgICAgY2FsbGJhY2soZmFsc2UpO1xuICAgICAgICB9XG4gICAgfTtcbiAgICB4aHIub25lcnJvciA9IChldmVudCkgPT4ge1xuICAgICAgICBjb25zb2xlLmxvZyhldmVudC5jdXJyZW50VGFyZ2V0LnN0YXR1cyk7XG4gICAgfTtcblxuICAgIGxldCB1cmwgPSAnJztcbiAgICBpZiAoaWQubWF0Y2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gKyAnLnBuZyc7XG4gICAgICAgIH1cblxuICAgICAgICB0aGlzLmxpbmsuYXBwZW5kQ2hpbGQodGhpcy5pbWcpO1xuICAgICAgICB0aGlzLmVsLmFwcGVuZENoaWxkKHRoaXMubGluayk7XG4gICAgICAgIHRoaXMuZWwuYXBwZW5kQ2hpbGQodGhpcy5jcmVkaXRzKTtcbiAgICAgICAgdGhpcy5tYWluLmNvbnRhaW5lci5hcHBlbmRDaGlsZCh0aGlzLmVsKTtcblxuICAgICAgICAvLyBBZGQgZXZlbnRzXG4gICAgICAgIGlmICh0aGlzLm9wdGlvbnMuaG92ZXJQcmV2aWV3KSB7XG4gICAgICAgICAgICB0aGlzLmVsLmFkZEV2ZW50TGlzdGVuZXIoJ21vdXNlZW50ZXInLCAoKSA9PiB7XG4gICAgICAgICAgICAgICAgb25FbnRlcih0aGlzKTtcbiAgICAgICAgICAgIH0pO1xuICAgICAgICAgICAgdGhpcy5lbC5hZGRFdmVudExpc3RlbmVyKCdtb3VzZWxlYXZlJywgKCkgPT4ge1xuICAgICAgICAgICAgICAgIG9uTGVhdmUodGhpcyk7XG4gICAgICAgICAgICB9KTtcbiAgICAgICAgfVxuXG4gICAgICAgIGlmICh0aGlzLm9wdGlvbnMub3BlbkZyYW1lSWNvbikge1xuICAgICAgICAgICAgdGhpcy5vcGVuRnJhbWVJY29uID0gbmV3IE9wZW5GcmFtZUljb24odGhpcyk7XG4gICAgICAgIH1cblxuICAgICAgICB0aGlzLmluaXQoKTtcbiAgICB9XG5cbiAgICBpbml0ICgpIHtcbiAgICAgICAgaWYgKCF0aGlzLnNvdXJjZSB8fCB0aGlzLnNvdXJjZSA9PT0gJycpIHtcbiAgICAgICAgICAgIHZhciB1cmwgPSAnJztcbiAgICAgICAgICAgIGlmICh0aGlzLmlkLm1hdGNoKC9cXGRcXGRcXC8uKi8pKSB7XG4gICAgICAgICAgICAgICAgdXJsID0gJ2h0dHA6Ly90aGVib29rb2ZzaGFkZXJzLmNvbS8nICsgdGhpcy5pZCArICcuZnJhZyc7XG4gICAgICAgICAgICB9XG4gICAgICAgICAgICBlbHNlIHtcbiAgICAgICAgICAgICAgICB1cmwgPSAnaHR0cDovL3RoZWJvb2tvZnNoYWRlcnMuY29tL2xvZy8nICsgdGhpcy5pZCArICcuZnJhZyc7XG4gICAgICAgICAgICB9XG4gICAgICAgICAgICBsZXQgaXRlbSA9IHRoaXM7XG4gICAgICAgICAgICB4aHIuZ2V0KHVybCwgKGVycm9yLCByZXMsIGJvZHkpID0+IHtcbiAgICAgICAgICAgICAgICBpZiAoZXJyb3IpIHtcbiAgICAgICAgICAgICAgICAgICAgY29uc29sZS5lcnJvcignRXJyb3IgZG93bmxvYWRpbmcgJywgZXJyb3IpO1xuICAgICAgICAgICAgICAgICAgICByZXR1cm47XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIGl0ZW0uc2V0Q29kZShib2R5KTtcbiAgICAgICAgICAgIH0pO1xuICAgICAgICB9XG4gICAgfVxuXG4gICAgbG9hZCAoY29kZSkge1xuICAgICAgICB0aGlzLnNldENvZGUoY29kZSk7XG4gICAgICAgIHdpbmRvdy5nbHNsR2FsbGVyeV9jYW52YXMubG9hZChjb2RlKTtcbiAgICAgICAgd2luZG93Lmdsc2xHYWxsZXJ5X2NhbnZhcy5jYW52YXMuc3R5bGUuaGVpZ2h0ID0gdGhpcy5pbWcub2Zmc2V0SGVpZ2h0ICsgJ3B4JztcbiAgICAgICAgdGhpcy5saW5rLmFwcGVuZENoaWxkKHdpbmRvdy5nbHNsR2FsbGVyeV9jYW52YXMuY2FudmFzKTtcbiAgICB9XG5cbiAgICBzZXRDb2RlIChjb2RlKSB7XG4gICAgICAgIHRoaXMuc291cmNlID0gY29kZTtcblxuICAgICAgICBpZiAoIXRoaXMuYXV0aG9yICYmIHRoaXMub3B0aW9ucy5zaG93QXV0aG9yKSB7XG4gICAgICAgICAgICB0aGlzLmF1dGhvciA9IHRoaXMuZ2V0QXV0aG9yKCk7XG4gICAg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GVuRnJhbWVJY29uID0gdHJ1ZTtcbiAgICAgICAgfVxuXG4gICAgICAgIGlmICghdGhpcy5vcHRpb25zLmNsaWNrUnVuKSB7XG4gICAgICAgICAgICB0aGlzLm9wdGlvbnMuY2xpY2tSdW4gPSAncGxheWVyJztcbiAgICAgICAgfVxuXG4gICAgICAgIHRoaXMuaXRlbXMgPSBbXTtcblxuICAgICAgICBpZiAoc2VsZWN0b3IuaGFzQXR0cmlidXRlKCdkYXRhLXByb3BlcnRpZXMnKSkge1xuICAgICAgICAgICAgbGV0IHByb3AgPSBzZWxlY3Rvci5nZXRBdHRyaWJ1dGUoJ2RhdGEtcHJvcGVydGllcycpLnNwbGl0KCcsJyk7XG4gICAgICAgICAgICBmb3IgKGxldCBpIGluIHByb3ApIHtcbiAgICAgICAgICAgICAgICBsZXQgdmFsdWVzID0gcHJvcFtpXS5zcGxpdCgnOicpO1xuICAgICAgICAgICAgICAgIGlmICh2YWx1ZXMubGVuZ3RoID09PSAxKSB7XG4gICAgICAgICAgICAgICAgICAgIHRoaXMub3B0aW9uc1t2YWx1ZXNbMF1dID0gdHJ1ZTtcbiAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgZWxzZSBpZiAodmFsdWVzLmxlbmd0aCA9PT0gMikge1xuICAgICAgICAgICAgICAgICAgICB0aGlzLm9wdGlvbnNbdmFsdWVzWzBdXSA9ICh2YWx1ZXNbMV0gPT09ICd0cnVlJyB8fCB2YWx1ZXNbMV0gPT09ICdmYWxzZScpID8gKHZhbHVlc1sxXSA9PT0gJ3RydWUnKSA6IHZhbHVlc1sxXTtcbiAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICB9XG4gICAgICAgIH1cblxuICAgICAgICBpZiAoc2VsZWN0b3IuaGFzQXR0cmlidXRlKCdkYXRhJykpIHtcbiAgICAgICAgICAgIGxldCBkYXRhID0gc2VsZWN0b3IuZ2V0QXR0cmlidXRlKCdkYXRhJykuc3BsaXQoJywnKTtcbiAgICAgICAgICAgIGZvciAobGV0IGkgaW4gZGF0YSkge1xuICAgICAgICAgICAgICAgIHRoaXMuaXRlbXMucHVzaChuZXcgR2FsbGVyeUl0ZW0oZGF0YVtpXSwgdGhpcywgdGhpcy5vcHRpb25zKSk7XG4gICAgICAgICAgICB9XG4gICAgICAgIH1cblxuICAgICAgICByZXR1cm4gdGhpcztcbiAgICB9XG5cbiAgICB2ZXJzaW9uKCkge1xuICAgICAgICByZXR1cm4gJzAuMC4xJztcbiAgICB9XG59XG5cbmZ1bmN0aW9uIGdsc2xHYWxsZXJ5TG9hZEFsbCgpIHtcbiAgICBpZiAoIXdpbmRvdy5HbHNsR2FsbGVyeSkge1xuICAgICAgICB3aW5kb3cuR2xzbEdhbGxlcnkgPSBHbHNsR2FsbGVyeTtcbiAgICB9XG5cbiAgICB2YXIgbGlzdCA9IGRvY3VtZW50LmdldEVsZW1lbnRzQnlDbGFzc05hbWUoJ2dsc2xHYWxsZXJ5Jyk7XG4gICAgaWYgKGxpc3QubGVuZ3RoID4gMCkge1xuICAgICAgICB3aW5kb3cuZ2xzbEdhbGxlcmllcyA9IFtdO1xuICAgICAgICBmb3IgKHZhciBpID0gMDsgaSA8IGxpc3QubGVuZ3RoOyBpKyspIHtcbiAgICAgICAgICAgIHZhciBnYWxsZXJ5ID0gbmV3IEdsc2xHYWxsZXJ5KGxpc3RbaV0pO1xuICAgICAgICAgICAgd2luZG93Lmdsc2xHYWxsZXJpZXMucHVzaChnYWxsZXJ5KTtcbiAgICAgICAgfVxuICAgIH1cbn1cblxud2luZG93Lm9ubG9hZCA9IGZ1bmN0aW9uICgpIHtcbiAgICBnbHNsR2FsbGVyeUxvYWRBbGwoKTtcbn07XG4iXX0=
diff --git a/examples_proto/src/shaderList.js b/examples_proto/src/examples.js
similarity index 79%
rename from examples_proto/src/shaderList.js
rename to examples_proto/src/examples.js
index 60a1f0a..7349711 100644
--- a/examples_proto/src/shaderList.js
+++ b/examples_proto/src/examples.js
@@ -108,6 +108,7 @@ var shaderList = {
"examples/06/tothn598-villareal",
"examples/06/wangl073-villareal"],
+
"advanced":[ "08/matrix",
"160414040957",
"160414040804",
@@ -122,8 +123,23 @@ var shaderList = {
"10/ikeda-numered-grid"]
};
-
-
-
+window.addEventListener("load", function () {
+ var options = {clickRun: 'editor'};
+ var elms = document.getElementsByClassName('glslChapterGallery');
+
+ for (var i = 0; i < elms.length; i++) {
+ var elm = elms[i];
+ if (elm.hasAttribute('data')) {
+ var data = elm.getAttribute('data').split(',');
+ if (data[1]) {
+ options.logs = shaderList[data[0]].slice(0, Number(data[1]));
+ } else {
+ options.logs = shaderList[data[0]];
+ }
+ console.log(options.logs);
+ var gallery = new GlslGallery(elm, options);
+ }
+ }
+});
diff --git a/examples_proto/src/glslGallery.js b/examples_proto/src/glslGallery.js
old mode 100644
new mode 100755
index e329839..3036be5
--- a/examples_proto/src/glslGallery.js
+++ b/examples_proto/src/glslGallery.js
@@ -2756,7 +2756,7 @@ function create3DContext(canvas, optAttribs) {
}
/*
- * Create a Vertex of a specific type (gl.VERTEX_SHADER/)
+ * Create a Vertex of a specific type (gl.VERTEX_SHADER/)
*/
function createShader(main, source, type) {
@@ -3934,19 +3934,38 @@ var GlslGallery = (function () {
}
if (selector.hasAttribute('data')) {
- var data = selector.getAttribute('data').split(',');
- for (var i in data) {
- this.items.push(new _appCoreGalleryItem2['default'](data[i], this, this.options));
- }
+ this.addItems(selector.getAttribute('data'));
+ }
+
+ if (this.options.logs) {
+ this.addItems(this.options.logs);
}
return this;
}
_createClass(GlslGallery, [{
+ key: 'addItem',
+ value: function addItem(log) {
+ if (typeof log === 'number') {
+ log = log.toString();
+ }
+ this.items.push(new _appCoreGalleryItem2['default'](log, this, this.options));
+ }
+ }, {
+ key: 'addItems',
+ value: function addItems(logs) {
+ if (typeof logs === 'string') {
+ logs = logs.split(',');
+ }
+ for (var i in logs) {
+ this.addItem(logs[i]);
+ }
+ }
+ }, {
key: 'version',
value: function version() {
- return '0.0.1';
+ return '0.0.5';
}
}]);
@@ -3970,100 +3989,11 @@ function glslGalleryLoadAll() {
}
}
-
-
-
-var GlslChapterGallery = (function () {
- function GlslChapterGallery(selector, options) {
- _classCallCheck(this, GlslChapterGallery);
-
- if (typeof selector === 'object' && selector.nodeType && selector.nodeType === 1) {
- this.container = selector;
- } else if (typeof selector === 'string') {
- this.container = document.querySelector(selector);
- } else {
- console.log('Error, type ' + typeof selector + ' of ' + selector + ' is unknown');
- return;
- }
-
- this.options = options || {};
-
- if (!this.options.showAuthor) {
- this.options.showAuthor = true;
- }
-
- if (!this.options.showTitle) {
- this.options.showTitle = true;
- }
-
- if (!this.options.hoverPreview) {
- this.options.hoverPreview = true;
- }
-
- if (!this.options.openFrameIcon) {
- this.options.openFrameIcon = true;
- }
-
- if (!this.options.clickRun) {
- this.options.clickRun = 'player';
- }
-
- this.items = [];
-
- if (selector.hasAttribute('data-properties')) {
- var prop = selector.getAttribute('data-properties').split(',');
- for (var i in prop) {
- var values = prop[i].split(':');
- if (values.length === 1) {
- this.options[values[0]] = true;
- } else if (values.length === 2) {
- this.options[values[0]] = values[1] === 'true' || values[1] === 'false' ? values[1] === 'true' : values[1];
- }
- }
- }
- if (selector.hasAttribute('data')) {
- var data = selector.getAttribute('data').split(',');
- var list = shaderList[data[0]];
- var numDisplay = (data[1]) ? Math.min(list.length, data[1]) : list.length;
-
- for (var i = 0; i < numDisplay; i ++) {
- this.items.push(new _appCoreGalleryItem2['default'](list[i], this, this.options));
- }
- }
-
- return this;
- }
-
- _createClass(GlslChapterGallery, [{
- key: 'version',
- value: function version() {
- return '0.0.1';
- }
- }]);
-
- return GlslChapterGallery;
-})();
-
-function loadChapterGalleries() {
- if (!window.GlslGallery) {
- window.GlslGallery = GlslGallery;
- }
-
- var list = document.getElementsByClassName('glslChapterGallery');
- if (list.length > 0) {
- window.glslGalleries = [];
- for (var i = 0; i < list.length; i++) {
- var gallery = new GlslChapterGallery(list[i]);
- window.glslGalleries.push(gallery);
- }
- }
-}
-
-window.addEventListener("load", function () {
- loadChapterGalleries();
+window.addEventListener('load', function () {
+ glslGalleryLoadAll();
});
module.exports = exports['default'];
},{"app/core/GalleryItem":17,"babel-runtime/helpers/class-call-check":2,"babel-runtime/helpers/create-class":3,"babel-runtime/helpers/interop-require-default":4}]},{},[18])(18)
});
-//# sourceMappingURL=data:application/json;charset:utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIm5vZGVfbW9kdWxlcy9icm93c2VyLXBhY2svX3ByZWx1ZGUuanMiLCJub2RlX21vZHVsZXMvYmFiZWwtcnVudGltZS9jb3JlLWpzL29iamVjdC9kZWZpbmUtcHJvcGVydHkuanMiLCJub2RlX21vZHVsZXMvYmFiZWwtcnVudGltZS9oZWxwZXJzL2NsYXNzLWNhbGwtY2hlY2suanMiLCJub2RlX21vZHVsZXMvYmFiZWwtcnVudGltZS9oZWxwZXJzL2NyZWF0ZS1jbGFzcy5qcyIsIm5vZGVfbW9kdWxlcy9iYWJlbC1ydW50aW1lL2hlbHBlcnMvaW50ZXJvcC1yZXF1aXJlLWRlZmF1bHQuanMiLCJub2RlX21vZHVsZXMvY29yZS1qcy9saWJyYXJ5L2ZuL29iamVjdC9kZWZpbmUtcHJvcGVydHkuanMiLCJub2RlX21vZHVsZXMvY29yZS1qcy9saWJyYXJ5L21vZHVsZXMvJC5qcyIsIm5vZGVfbW9kdWxlcy9mb3ItZWFjaC9pbmRleC5qcyIsIm5vZGVfbW9kdWxlcy9nbG9iYWwvd2luZG93LmpzIiwibm9kZV9tb2R1bGVzL2dsc2xDYW52YXMvYnVpbGQvbm9kZV9tb2R1bGVzL2dsc2xDYW52YXMvYnVpbGQvbm9kZV9tb2R1bGVzL2Jyb3dzZXItcGFjay9fcHJlbHVkZS5qcyIsIm5vZGVfbW9kdWxlcy9nbHNsQ2FudmFzL2J1aWxkL25vZGVfbW9kdWxlcy9nbHNsQ2FudmFzL2J1aWxkL25vZGVfbW9kdWxlcy9iYWJlbC1ydW50aW1lL2NvcmUtanMvYXJy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gICAgIC8vIDIzLjEuMy43IE1hcC5wcm90b3R5cGUuaGFzKGtleSlcbiAgICAgIC8vIDIzLjIuMy43IFNldC5wcm90b3R5cGUuaGFzKHZhbHVlKVxuICAgICAgaGFzOiBmdW5jdGlvbiBoYXMoa2V5KXtcbiAgICAgICAgcmV0dXJuICEhZ2V0RW50cnkodGhpcywga2V5KTtcbiAgICAgIH1cbiAgICB9KTtcbiAgICBpZihERVNDUklQVE9SUykkLnNldERlc2MoQy5wcm90b3R5cGUsICdzaXplJywge1xuICAgICAgZ2V0OiBmdW5jdGlvbigpe1xuICAgICAgICByZXR1cm4gZGVmaW5lZCh0aGlzW1NJWkVdKTtcbiAgICAgIH1cbiAgICB9KTtcbiAgICByZXR1cm4gQztcbiAgfSxcbiAgZGVmOiBmdW5jdGlvbih0aGF0LCBrZXksIHZhbHVlKXtcbiAgICB2YXIgZW50cnkgPSBnZXRFbnRyeSh0aGF0LCBrZXkpXG4gICAgICAsIHByZXYsIGluZGV4O1xuICAgIC8vIGNoYW5nZSBleGlzdGluZyBlbnRyeVxuICAgIGlmKGVudHJ5KXtcbiAgICAgIGVudHJ5LnYgPSB2YWx1ZTtcbiAgICAvLyBjcmVhdGUgbmV3IGVudHJ5XG4gICAgfSBlbHNlIHtcbiAgICAgIHRoYXQuX2wgPSBlbnRyeSA9IHtcbiAgICAgICAgaTogaW5kZXggPSBmYXN0S2V5KGtleSwgdHJ1ZSksIC8vIDwtIGluZGV4XG4gICAgICAgIGs6IGtleSwgICAgICAgICAgICAgICAgICAgICAgICAvLyA8LSBrZXlcbiAgICAgICAgdjogdmFsdWUsICAgICAgICAgICAgICAgICAgICAgIC8vIDwtIHZhbHVlXG4gICAgICAgIHA6IHByZXYgPSB0aGF0Ll9sLCAgICAgICAgICAgICAvLyA8LSBwcmV2aW91cyBlbnRyeVxuICAgICAgICBuOiB1bmRlZmluZWQsICAgICAgICAgICAgICAgICAgLy8gPC0gbmV4dCBlbnRyeVxuICAgICAgICByOiBmYWxzZS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AvLyB3cmFwXG4gIH1cbn07XG5cbi8vIGNvbnN0cnVjdG9yIHBvbHlmaWxsXG5pZighVVNFX05BVElWRSl7XG4gIC8vIDI1LjQuMy4xIFByb21pc2UoZXhlY3V0b3IpXG4gIFAgPSBmdW5jdGlvbiBQcm9taXNlKGV4ZWN1dG9yKXtcbiAgICBhRnVuY3Rpb24oZXhlY3V0b3IpO1xuICAgIHZhciByZWNvcmQgPSB0aGlzLl9kID0ge1xuICAgICAgcDogc3RyaWN0TmV3KHRoaXMsIFAsIFBST01JU0UpLCAgICAgICAgIC8vIDwtIHByb21pc2VcbiAgICAgIGM6IFtdLCAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAvLyA8LSBhd2FpdGluZyByZWFjdGlvbnNcbiAgICAgIGE6IHVuZGVmaW5lZCwgICAgICAgICAgICAgICAgICAgICAgICAgICAvLyA8LSBjaGVja2VkIGluIGlzVW5oYW5kbGVkIHJlYWN0aW9uc1xuICAgICAgczogMCwgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIC8vIDwtIHN0YXRlXG4gICAgICBkOiBmYWxzZSwgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgLy8gPC0gZG9uZVxuICAgICAgdjogdW5kZWZpbmVkLCAgICAgICAgICAgICAgICAgICAgICAgICAgIC8vIDwtIHZhbHVlXG4gICAgICBoOiBmYWxzZSwgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgLy8gPC0gaGFuZGxlZCByZWplY3Rpb25cbiAgICAgIG46IGZhbHNlICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAvLyA8LSBub3RpZnlcbiAgICB9O1xuICAgIHRyeSB7XG4gICAgICBleGVjdXRvcihjdHgoJHJlc29sdmUsIHJlY29yZCwgMSksIGN0eCgkcmVqZWN0LCByZWNvcmQsIDEpKTtcbiAgICB9IGNhdGNoKGVycil7XG4gICAgICAkcmVqZWN0LmNhbGwocmVjb3JkLCBlcnIpO1xuICAgIH1cbiAgfTtc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xuICAsIGlzQXJyYXkgPSBmdW5jdGlvbihhcmcpIHtcbiAgICAgIHJldHVybiBPYmplY3QucHJvdG90eXBlLnRvU3RyaW5nLmNhbGwoYXJnKSA9PT0gJ1tvYmplY3QgQXJyYXldJztcbiAgICB9XG5cbm1vZHVsZS5leHBvcnRzID0gZnVuY3Rpb24gKGhlYWRlcnMpIHtcbiAgaWYgKCFoZWFkZXJzKVxuICAgIHJldHVybiB7fVxuXG4gIHZhciByZXN1bHQgPSB7fVxuXG4gIGZvckVhY2goXG4gICAgICB0cmltKGhlYWRlcnMpLnNwbGl0KCdcXG4nKVxuICAgICwgZnVuY3Rpb24gKHJvdykge1xuICAgICAgICB2YXIgaW5kZXggPSByb3cuaW5kZXhPZignOicpXG4gICAgICAgICAgLCBrZXkgPSB0cmltKHJvdy5zbGljZSgwLCBpbmRleCkpLnRvTG93ZXJDYXNlKClcbiAgICAgICAgICAsIHZhbHVlID0gdHJpbShyb3cuc2xpY2UoaW5kZXggKyAxKSlcblxuICAgICAgICBpZiAodHlwZW9mKHJlc3VsdFtrZXldKSA9PT0gJ3VuZGVmaW5lZCcpIHtcbiAgICAgICAgICByZXN1bHRba2V5XSA9IHZhbHVlXG4gICAgICAgIH0gZWxzZSBpZiAoaXNBcnJheShyZXN1bHRba2V5XSkpIHtcbiAgICAgICAgICByZXN1bHRba2V5XS5wdXNoKHZhbHVlKVxuICAgICAgICB9IGVsc2Uge1xuICAgICAgICAgIHJlc3VsdFtrZXldID0gWyByZXN1bHRba2V5XSwgdmFsdWUgXVxuICAgICAgICB9XG4gICAgICB9XG4gIClcblxuICByZXR1cm4gcmVzdWx0XG59IiwiXG5leHBvcnRzID0gbW9kdWxlLmV4cG9ydHMgPSB0cmltO1xuXG5mdW5jdGlvbiB0cmltKHN0cil7XG4gIHJldHVybiBzdHIucmVwbGFjZSgvXlxccyp8XFxzKiQvZywgJycpO1xufVxuXG5leHBvcnRzLmxlZnQgPSBmdW5jdGlvbihzdHIpe1xuICByZXR1cm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9IDIwMFxuICAgICAgICB9IGVsc2Uge1xuICAgICAgICAgICAgc3RhdHVzID0gKHhoci5zdGF0dXMgPT09IDEyMjMgPyAyMDQgOiB4aHIuc3RhdHVzKVxuICAgICAgICB9XG4gICAgICAgIHZhciByZXNwb25zZSA9IGZhaWx1cmVSZXNwb25zZVxuICAgICAgICB2YXIgZXJyID0gbnVsbFxuXG4gICAgICAgIGlmIChzdGF0dXMgIT09IDApe1xuICAgICAgICAgICAgcmVzcG9uc2UgPSB7XG4gICAgICAgICAgICAgICAgYm9keTogZ2V0Qm9keSgpLFxuICAgICAgICAgICAgICAgIHN0YXR1c0NvZGU6IHN0YXR1cyxcbiAgICAgICAgICAgICAgICBtZXRob2Q6IG1ldGhvZCxcbiAgICAgICAgICAgICAgICBoZWFkZXJzOiB7fSxcbiAgICAgICAgICAgICAgICB1cmw6IHVyaSxcbiAgICAgICAgICAgICAgICByYXdSZXF1ZXN0OiB4aHJcbiAgICAgICAgICAgIH1cbiAgICAgICAgICAgIGlmKHhoci5nZXRBbGxSZXNwb25zZUhlYWRlcnMpeyAvL3JlbWVtYmVyIHhociBjYW4gaW4gZmFjdCBiZSBYRFIgZm9yIENPUlMgaW4gSUVcbiAgICAgICAgICAgICAgICByZXNwb25zZS5oZWFkZXJzID0gcGFyc2VIZWFkZXJzKHhoci5nZXRBbGxSZXNwb25zZUhlYWRlcnMoKSlcbiAgICAgICAgICAgIH1cbiAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgIGVyciA9IG5ldyBFcnJvcihcIkludGVybmFsIFhNTEh0dHBSZXF1ZXN0IEVycm9yXCIpXG4gICAgICAgIH1cbiAgICAgICAgY2FsbGJhY2soZXJyLCByZXNwb25zZSwgcmVzcG9uc2UuYm9keSlcblxuICAgIH1cblxuICAgIHZhciB4aHIgPSBvcHRpb25zLnhociB8fCBudWxsXG5cbiAgICBpZiAoIXhocikge1xuICAgICAgICBpZiAob3B0aW9ucy5jb3JzIHx8IG9wdGlvbnMudXNlWER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aXQoJywnKTtcbiAgICAgICAgICAgIGZvciAobGV0IG5JbWcgaW4gaW1nTGlzdCkge1xuICAgICAgICAgICAgICAgIHRoaXMuc2V0VW5pZm9ybSgndV90ZXgnICsgbkltZywgaW1nTGlzdFtuSW1nXSk7XG4gICAgICAgICAgICB9XG4gICAgICAgIH1cblxuICAgICAgICAvLyA9PT09PT09PT09PT09PT09PT09PT09PT09PSBFVkVOVFNcbiAgICAgICAgbGV0IG1vdXNlID0ge1xuICAgICAgICAgICAgeDogMCxcbiAgICAgICAgICAgIHk6IDBcbiAgICAgICAgfTtcbiAgICAgICAgZG9jdW1lbnQuYWRkRXZlbnRMaXN0ZW5lcignbW91c2Vtb3ZlJywgKGUpID0+IHtcbiAgICAgICAgICAgIG1vdXNlLnggPSBlLmNsaWVudFggfHwgZS5wYWdlWDtcbiAgICAgICAgICAgIG1vdXNlLnkgPSBlLmNsaWVudFkgfHwgZS5wYWdlWTtcbiAgICAgICAgfSwgZmFsc2UpO1xuXG4gICAgICAgIGxldCBzYW5kYm94ID0gdGhpcztcbiAgICAgICAgZnVuY3Rpb24gUmVuZGVyTG9vcCgpIHtcbiAgICAgICAgICAgIHNhbmRib3guc2V0TW91c2UobW91c2UpO1xuICAgICAgICAgICAgc2FuZGJveC5yZW5kZXIoKTtcbiAgICAgICAgICAgIHNhbmRib3guZm9yY2VSZW5kZXIgPSBzYW5kYm94LnJlc2l6ZSgpO1xuICAgICAgICAgICAgd2luZG93LnJlcXVlc3RBbmltYXRpb25GcmFtZShSZW5kZXJMb29wKTtcbiAgICAgICAgfVxuXG4gICAgICAgIC8vIFN0YXJ0XG4gICAgICAgIHRoaXMuc2V0TW91c2UoeyB4OiAwLCB5OiAwIH0pO1xuICAgICAgICBSZW5kZXJMb29wKCk7XG4gICAgICAgIHJldHVybiB0aGlzO1xuICAgIH1cblxuICAgIGRlc3Ryb3koKSB7XG4gICAgICAgIHRoaXMuYW5pbWF0ZWQgPSBmYWxzZTtcbiAgICAgICAgdGhpcy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ICB9XG4gICAgfVxuXG4gICAgcmVuZGVyICgpIHtcbiAgICAgICAgdGhpcy52aXNpYmxlID0gaXNDYW52YXNWaXNpYmxlKHRoaXMuY2FudmFzKTtcbiAgICAgICAgaWYgKHRoaXMuZm9yY2VSZW5kZXIgfHxcbiAgICAgICAgICAgICh0aGlzLmFuaW1hdGVkICYmIHRoaXMudmlzaWJsZSkpIHtcbiAgICAgICAgICAgIC8vIHNldCB0aGUgdGltZSB1bmlmb3JtXG4gICAgICAgICAgICBsZXQgdGltZUZyYW1lID0gRGF0ZS5ub3coKTtcbiAgICAgICAgICAgIGxldCB0aW1lID0gKHRpbWVGcmFtZSAtIHRoaXMudGltZUxvYWQpIC8gMTAwMC4wO1xuICAgICAgICAgICAgdGhpcy51bmlmb3JtKCcxZicsICdmbG9hdCcsICd1X3RpbWUnLCB0aW1lKTtcblxuICAgICAgICAgICAgLy8gc2V0IHRoZSByZXNvbHV0aW9uIHVuaWZvcm1cbiAgICAgICAgICAgIHRoaXMudW5pZm9ybSgnMmYnLCAndmVjMicsICd1X3Jlc29sdXRpb24nLCB0aGlzLmNhbnZhcy53aWR0aCwgdGhpcy5jYW52YXMuaGVpZ2h0KTtcblxuICAgICAgICAgICAgdGhpcy50ZXh1cmVJbmRleCA9IDA7XG4gICAgICAgICAgICBmb3IgKGxldCB0ZXggaW4gdGhpcy50ZXh0dXJlcykge1xuICAgICAgICAgICAgICAgIHRoaXMudW5pZm9ybVRleHR1cmUodGV4KTtcbiAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgLy8gRHJhdyB0aGUgcmVjdGFuZ2xlLlxuICAgICAgICAgICAgdGhpcy5nbC5kcmF3QXJyYXlzKHRoaXMuZ2wuVFJJQU5HTEVTLCAwLCA2KTtcblxuICAgICAgICAgICAgLy8gVHJpZ2dlciBldmVudFxuICAgICAgICAgICAgdGhpcy50cmlnZ2VyKCdyZW5kZXInLCB7fSk7XG5cbiAgICAgICAgICAgIHRoaXMuY2hhbmdlID0gZmFsc2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gICB9XG5cbiAgICAvLyBEZXN0cm95IGEgc2luZ2xlIHRleHR1cmUgaW5zdGFuY2VcbiAgICBkZXN0cm95KCkge1xuICAgICAgICBpZiAoIXRoaXMudmFsaWQpIHtcbiAgICAgICAgICAgIHJldHVybjtcbiAgICAgICAgfVxuICAgICAgICB0aGlzLmdsLmRlbGV0ZVRleHR1cmUodGhpcy50ZXh0dXJlKTtcbiAgICAgICAgdGhpcy50ZXh0dXJlID0gbnVsbDtcbiAgICAgICAgZGVsZXRlIHRoaXMuZGF0YTtcbiAgICAgICAgdGhpcy5kYXRhID0gbnVsbDtcbiAgICAgICAgdGhpcy52YWxpZCA9IGZhbHNlO1xuICAgIH1cblxuICAgIGJpbmQodW5pdCkge1xuICAgICAgICBpZiAoIXRoaXMudmFsaWQpIHtcbiAgICAgICAgICAgIHJldHVybjtcbiAgICAgICAgfVxuICAgICAgICBpZiAodHlwZW9mIHVuaXQgPT09ICdudW1iZXInKSB7XG4gICAgICAgICAgICBpZiAoVGV4dHVyZS5hY3RpdmVVbml0ICE9PSB1bml0KSB7XG4gICAgICAgICAgICAgICAgdGhpcy5nbC5hY3RpdmVUZXh0dXJlKHRoaXMuZ2wuVEVYVFVSRTAgKyB1bml0KTtcbiAgICAgICAgICAgICAgICBUZXh0dXJlLmFjdGl2ZVVuaXQgPSB1bml0O1xuICAgICAgICAgICAgfVxuICAgICAgICB9XG4gICAgICAgIGlmIChUZXh0dXJlLmFjdGl2ZVRleHR1cmUgIT09IHRoaXMudGV4dHVyZSkge1xuICAgICAgICAgICAgdGhpcy5nbC5iaW5kVGV4dHVyZSh0aGlzLmdsLlRFWFRVUkVfMkQsIHRoaXMudGV4dHVyZSk7XG4gICAgICAgICAgICBUZXh0dXJlLmFjdGl2ZVRleHR1cmUgPSB0aGlzLnRleHR1cmU7XG4gICAgICAgIH1cbiAgICB9XG5cbiAgICBsb2FkKG9wdGlvbnMgPSB7fSkge1xuICAgICAgICB0aGlzLmxvYWRpbmcgPSBudWxsO1x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ICAgICAgICAgICAgICB0aGlzLnNldEVsZW1lbnQoaW1hZ2UsIG9wdGlvbnMpO1xuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICBjYXRjaCAoZSkge1xuICAgICAgICAgICAgICAgICAgICBjb25zb2xlLmxvZyhgVGV4dHVyZSAnJHt0aGlzLm5hbWV9JzogZmFpbGVkIHRvIGxvYWQgdXJsOiAnJHt0aGlzLnNvdXJjZX0nYCwgZSwgb3B0aW9ucyk7XG4gICAgICAgICAgICAgICAgfVxuXG4gICAgICAgICAgICAgICAgcmVzb2x2ZSh0aGlzKTtcbiAgICAgICAgICAgIH07XG4gICAgICAgICAgICBpbWFnZS5vbmVycm9yID0gZSA9PiB7XG4gICAgICAgICAgICAgICAgLy8gV2FybiBhbmQgcmVzb2x2ZSBvbiBlcnJvclxuICAgICAgICAgICAgICAgIGNvbnNvbGUubG9nKGBUZXh0dXJlICcke3RoaXMubmFtZX0nOiBmYWlsZWQgdG8gbG9hZCB1cmw6ICcke3RoaXMuc291cmNlfSdgLCBlLCBvcHRpb25zKTtcbiAgICAgICAgICAgICAgICByZXNvbHZlKHRoaXMpO1xuICAgICAgICAgICAgfTtcbiAgICAgICAgICAgIGltYWdlLmNyb3NzT3JpZ2luID0gJ2Fub255bW91cyc7XG4gICAgICAgICAgICBpbWFnZS5zcmMgPSB0aGlzLnNvdXJjZTtcbiAgICAgICAgfSk7XG4gICAgICAgIHJldHVybiB0aGlzLmxvYWRpbmc7XG4gICAgfVxuXG4gICAgLy8gU2V0cyB0ZXh0dXJlIHRvIGEgcmF3IGltYWdlIGJ1ZmZlclxuICAgIHNldERhdGEod2lkdGgsIGhlaWdodCwgZGF0YSwgb3B0aW9ucyA9IHt9KSB7XG4gICAgICAgIHRoaXMud2lkdGggPSB3aWR0aDtcbiAgICAgICAgdGhpcy5oZWlnaHQgPSBoZWlnaHQ7XG5cbiAgICAgICAgdGhpcy5zb3VyY2UgPSBkYXRhO1xuICAgICAgICB0aGlzLnNvdX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lbmd0aCA9PT0gMSkge1xuICAgICAgICAgICAgICAgICAgICBwYXJzZWQucHVzaCh7XG4gICAgICAgICAgICAgICAgICAgICAgICB0eXBlOiAnZmxvYXQnLFxuICAgICAgICAgICAgICAgICAgICAgICAgbWV0aG9kOiAnMWYnLFxuICAgICAgICAgICAgICAgICAgICAgICAgbmFtZSxcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhbHVlOiB1bmlmb3JtXG4gICAgICAgICAgICAgICAgICAgIH0pO1xuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICAvLyBmbG9hdCB2ZWN0b3JzICh2ZWMyLCB2ZWMzLCB2ZWM0KVxuICAgICAgICAgICAgICAgIGVsc2UgaWYgKHVuaWZvcm0ubGVuZ3RoID49IDIgJiYgdW5pZm9ybS5sZW5ndGggPD0gNCkge1xuICAgICAgICAgICAgICAgICAgICBwYXJzZWQucHVzaCh7XG4gICAgICAgICAgICAgICAgICAgICAgICB0eXBlOiAndmVjJyArIHVuaWZvcm0ubGVuZ3RoLFxuICAgICAgICAgICAgICAgICAgICAgICAgbWV0aG9kOiB1bmlmb3JtLmxlbmd0aCArICdmdicsXG4gICAgICAgICAgICAgICAgICAgICAgICBuYW1lLFxuICAgICAgICAgICAgICAgICAgICAgICAgdmFsdWU6IHVuaWZvcm1cbiAgICAgICAgICAgICAgICAgICAgfSk7XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIC8vIGZsb2F0IGFycmF5XG4gICAgICAgICAgICAgICAgZWxzZSBpZiAodW5pZm9ybS5sZW5ndGggPiA0KSB7XG4gICAgICAgICAgICAgICAgICAgIHBhcnNlZC5wdXNoKHtcbiAgICAgICAgICAgICAgICAgICAgICAgIHR5cGU6ICdmbG9hdFtdJyxcbiAgICAgICAgICAgICAgICAgICAgICAgIG1ldGhvZDogJzFmdicsXG4gICAgICAgICAgICAgICAgICAgICAgICBuYW1lOiBuYW1lICsgJ1swXScsXG4gICAgICAgICAgICAgICAgICAgICAgICB2YWx1ZTogdW5pZm9ybVxuICAgICAgICAgICAgICAgICAgICB9KTtcbiAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgLy8gVE9ETzogYXNzdW1lIG1hdHJpeCBmb3IgKHR5cGVvZiA9PSBGbG9hdDMyQXJyYXkgJiYgbGVuZ3RoID09IDE2KT9cbiAgICAgICAgICAgIH1cbiAgICAgICAgICAgIC8vIEFycmF5IG9mIHRleHR1cmVzXG4gICAgICAgICAgICBlbHNlIGlmICh0eXBlb2YgdW5pZm9ybVswXSA9PT0gJ3N0cmluZycpIHtcbiAgICAgICAgICAgICAgICBwYXJzZWQucHVzaCh7XG4gICAgICAgICAgICAgICAgICAgIHR5cGU6ICdzYW1wbGVyMkQnLFxuICAgICAgICAgICAgICAgICAgICBtZXRob2Q6ICcxaScsXG4gICAgICAgICAgICAgICAgICAgIG5hbWU6IG5hbWUsXG4gICAgICAgICAgICAgICAgICAgIHZhbHVlOiB1bmlmb3JtXG4gICAgICAgICAgICAgICAgfSk7XG4gICAgICAgICAgICB9XG4gICAgICAgICAgICAvLyBBcnJheSBvZiBhcnJheXMgLSBidXQgb25seSBhcnJheXMgb2YgdmVjdG9ycyBhcmUgYWxsb3dlZCBpbiB0aGlzIGNhc2VcbiAgICAgICAgICAgIGVsc2UgaWYgKEFycmF5LmlzQXJyYXkodW5pZm9ybVswXSkgJiYgdHlwZW9mIHVuaWZvcm1bMF1bMF0gPT09ICdudW1iZXInKSB7XG4gICAgICAgICAgICAgICAgLy8gZmxvYXQgdmVjdG9ycyAodmVjMiwgdmVjMywgdmVjNClcbiAgICAgICAgICAgICAgICBpZiAodW5pZm9ybVswXS5sZW5ndGggPj0gMiAmJiB1bmlmb3JtWzBdLmxlbmd0aCA8PSA0KSB7XG4gICAgICAgICAgICAgICAgICAgIC8vIFNldCBlYWNoIHZlY3RvciBpbiB0aGUgYXJyYXlcbiAgICAgICAgICAgICAgICAgICAgZm9yICh1ID0gMDsgdSA8IHVuaWZvcm0ubGVuZ3RoOyB1KyspIHtcbiAgICAgICAgICAgICAgICAgICAgICAgIHBhcnNlZC5wdXNoKHtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB0eXBlOiAndmVjJyArIHVuaWZvcm1bMF0ubGVuZ3RoLFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIG1ldGhvZDogdW5pZm9ybVt1XS5sZW5ndGggKyAnZnYnLFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIG5hbWU6IG5hbWUgKyAnWycgKyB1ICsgJ10nLFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHZhbHVlOiB1bmlmb3JtW3VdXG4gICAgICAgICAgICAgICAgICAgICAgICB9KTtcbiAgICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICAvLyBlbHNlIGVycm9yP1xuICAgICAgICAgICAgfVxuICAgICAgICAgICAgLy8gQXJyYXkgb2Ygc3RydWN0dXJlc1xuICAgICAgICAgICAgZWxzZSBpZiAodHlwZW9mIHVuaWZvcm1bMF0gPT09ICdvYmplY3QnKSB7XG4gICAgICAgICAgICAgICAgZm9yICh1ID0gMDsgdSA8IHVuaWZvcm0ubGVuZ3RoOyB1KyspIHtcbiAgICAgICAgICAgICAgICAgICAgLy8gU2V0IGVhY2ggc3RydWN0IGluIHRoZSBhcnJheVxuICAgICAgICAgICAgICAgICAgICBwYXJzZWQucHVzaCguLi5wYXJzZVVuaWZvcm1zKHVuaWZvcm1bdV0sIG5hbWUgKyAnWycgKyB1ICsgJ10nKSk7XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgfVxuICAgICAgICB9XG4gICAgICAgIC8vIEJvb2xlYW5cbiAgICAgICAgZWxzZSBpZiAodHlwZW9mIHVuaWZvcm0gPT09ICdib29sZWFuJykge1xuICAgICAgICAgICAgcGFyc2VkLnB1c2goe1xuICAgICAgICAgICAgICAgIHR5cGU6ICdib29sJyxcbiAgICAgICAgICAgICAgICBtZXRob2Q6ICcxaScsXG4gICAgICAgICAgICAgICAgbmFtZSxcbiAgICAgICAgICAgICAgICB2YWx1ZTogdW5pZm9ybVxuICAgICAgICAgICAgfSk7XG4gICAgICAgIH1cbiAgICAgICAgLy8gVGV4dHVyZVxuICAgICAgICBlbHNlIGlmICh0eXBlb2YgdW5pZm9ybSA9PT0gJ3N0cmluZycpIHtcbiAgICAgICAgICAgIHBhcnNlZC5wdXNoKHtcbiAgICAgICAgICAgICAgICB0eXBlOiAnc2FtcGxlcjJEJyxcbiAgICAgICAgICAgICAgICBtZXRob2Q6ICcxaScsXG4gICAgICAgICAgICAgICAgbmFtZSxcbiAgICAgICAgICAgICAgICB2YWx1ZTogdW5pZm9ybVxuICAgICAgICAgICAgfSk7XG4gICAgICAgIH1cbiAgICAgICAgLy8gU3RydWN0dXJlXG4gICAgICAgIGVsc2UgaWYgKHR5cGVvZiB1bmlmb3JtID09PSAnb2JqZWN0Jykge1xuICAgICAgICAgICAgLy8gU2V0IGVhY2ggZmllbGQgaW4gdGhlIHN0cnVjdFxuICAgICAgICAgICAgcGFyc2VkLnB1c2goLi4ucGFyc2VVbmlmb3Jtcyh1bmlmb3JtLCBuYW1lKSk7XG4gICAgICAgIH1cbiAgICAgICAgLy8gVE9ETzogc3VwcG9ydCBvdGhlciBub24tZmxvYXQgdHlwZXM/IChpbnQsIGV0Yy4pXG4gICAgfVxuICAgIHJldHVybiBwYXJzZWQ7XG59XG4iLCJleHBvcnQgZnVuY3Rpb24gaXNDYW52YXNWaXNpYmxlKGNhbnZhcykge1xuICAgIHJldHVyblx0KChjYW52YXMuZ2V0Qm91bmRpbmdDbGllbnRSZWN0KCkudG9wICsgY2FudmFzLmhlaWdodCkgPiAwKSAmJlxuICAgICAgICAoY2FudmFzLmdldEJvdW5kaW5nQ2xpZW50UmVjdCgpLnRvcCA8ICh3aW5kb3cuaW5uZXJIZWlnaHQgfHwgZG9jdW1lbnQuZG9jdW1lbnRFbGVtZW50LmNsaWVudEhlaWdodCkp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5cbiAgICAgICAgc3Vic2NyaWJlKGxpc3RlbmVyKSB7XG4gICAgICAgICAgICBsaXN0ZW5lcnMuYWRkKGxpc3RlbmVyKTtcbiAgICAgICAgfSxcblxuICAgICAgICBvbih0eXBlLCBmKSB7XG4gICAgICAgICAgICBsZXQgbGlzdGVuZXIgPSB7fTtcbiAgICAgICAgICAgIGxpc3RlbmVyW3R5cGVdID0gZjtcbiAgICAgICAgICAgIGxpc3RlbmVycy5hZGQobGlzdGVuZXIpO1xuICAgICAgICB9LFxuXG4gICAgICAgIHVuc3Vic2NyaWJlKGxpc3RlbmVyKSB7XG4gICAgICAgICAgICBsaXN0ZW5lcnMuZGVsZXRlKGxpc3RlbmVyKTtcbiAgICAgICAgfSxcblxuICAgICAgICB1bnN1YnNjcmliZUFsbCgpIHtcbiAgICAgICAgICAgIGxpc3RlbmVycy5jbGVhcigpO1xuICAgICAgICB9LFxuXG4gICAgICAgIHRyaWdnZXIoZXZlbnQsIC4uLmRhdGEpIHtcbiAgICAgICAgICAgIGZvciAodmFyIGxpc3RlbmVyIG9mIGxpc3RlbmVycykge1xuICAgICAgICAgICAgICAgIGlmICh0eXBlb2YgbGlzdGVuZXJbZXZlbnRdID09PSAnZnVuY3Rpb24nKSB7XG4gICAgICAgICAgICAgICAgICAgIGxpc3RlbmVyW2V2ZW50XSguLi5kYXRhKTtcbiAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICB9XG4gICAgICAgIH1cbiAgICB9KTtcbn1cbiIsImV4cG9ydCBmdW5jdGlvbiBzdWJzY3JpYmVNaXhpbiAodGFyZ2V0KSB7XG4gICAgdmFyIGxpc3RlbmVycyA9IG5ldyBTZXQoKTtcblxuICAgIHJldHVybiBPYmplY3QuYXNzaWduKHRhcmdldCwge1xuXG4gICAgICAgIG9uKHR5cGUsIGYpIHtcbiAgICAgICAgICAgIGxldCBsaXN0ZW5lciA9IHt9O1xuICAgICAgICAgICAgbGlzdGVuZXJbdHlwZV0gPSBmO1xuICAgICAgICAgICAgbGlzdGVuZXJzLmFkZChsaXN0ZW5lcik7XG4gICAgICAgIH0sXG5cbiAgICAgICAgb2ZmKHR5cGUsIGYpIHtcbiAgICAgICAgICAgIGlmIChmKSB7XG4gICAgICAgICAgICAgICAgbGV0IGxpc3RlbmVyID0ge307XG4gICAgICAgICAgICAgICAgbGlzdGVuZXJbdHlwZV0gPSBmO1xuICAgICAgICAgICAgICAgIGxpc3RlbmVycy5kZWxldGUobGlzdGVuZXIpO1xuICAgICAgICAgICAgfVxuICAgICAgICAgICAgZWxzZSB7XG4gICAgICAgICAgICAgICAgZm9yIChsZXQgaXRlbSBvZiBsaXN0ZW5lcnMpIHtcbiAgICAgICAgICAgICAgICAgICAgZm9yIChsZXQga2V5IG9mIE9iamVjdC5rZXlzKGl0ZW0pKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICBpZiAoa2V5ID09PSB0eXBlKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgbGlzdGVuZXJzLmRlbGV0ZShpdGVtKTtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm47XG4gICAgICAgICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICB9XG4gICAgICAgIH0sXG5cbiAgICAgICAgbGlzdFN1YnNjcmlwdGlvbnMoKSB7XG4gICAgICAgICAgICBmb3IgKGxldCBpdGVtIG9mIGxpc3RlbmVycykge1xuICAgICAgICAgICAgICAgIGNvbnNvbGUubG9nKGl0ZW0pO1xuICAgICAgICAgICAgfVxuICAgICAgICB9LFxuXG4gICAgICAgIHN1YnNjcmliZShsaXN0ZW5lcikge1xuICAgICAgICAgICAgbGlzdGVuZXJzLmFkZChsaXN0ZW5lcik7XG4gICAgICAgIH0sXG5cbiAgICAgICAgdW5zdWJzY3JpYmUobGlzdGVuZXIpIHtcbiAgICAgICAgICAgIGxpc3RlbmVycy5kZWxldGUobGlzdGVuZXIpO1xuICAg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VxuICAsIGlzQXJyYXkgPSBmdW5jdGlvbihhcmcpIHtcbiAgICAgIHJldHVybiBPYmplY3QucHJvdG90eXBlLnRvU3RyaW5nLmNhbGwoYXJnKSA9PT0gJ1tvYmplY3QgQXJyYXldJztcbiAgICB9XG5cbm1vZHVsZS5leHBvcnRzID0gZnVuY3Rpb24gKGhlYWRlcnMpIHtcbiAgaWYgKCFoZWFkZXJzKVxuICAgIHJldHVybiB7fVxuXG4gIHZhciByZXN1bHQgPSB7fVxuXG4gIGZvckVhY2goXG4gICAgICB0cmltKGhlYWRlcnMpLnNwbGl0KCdcXG4nKVxuICAgICwgZnVuY3Rpb24gKHJvdykge1xuICAgICAgICB2YXIgaW5kZXggPSByb3cuaW5kZXhPZignOicpXG4gICAgICAgICAgLCBrZXkgPSB0cmltKHJvdy5zbGljZSgwLCBpbmRleCkpLnRvTG93ZXJDYXNlKClcbiAgICAgICAgICAsIHZhbHVlID0gdHJpbShyb3cuc2xpY2UoaW5kZXggKyAxKSlcblxuICAgICAgICBpZiAodHlwZW9mKHJlc3VsdFtrZXldKSA9PT0gJ3VuZGVmaW5lZCcpIHtcbiAgICAgICAgICByZXN1bHRba2V5XSA9IHZhbHVlXG4gICAgICAgIH0gZWxzZSBpZiAoaXNBcnJheShyZXN1bHRba2V5XSkpIHtcbiAgICAgICAgICByZXN1bHRba2V5XS5wdXNoKHZhbHVlKVxuICAgICAgICB9IGVsc2Uge1xuICAgICAgICAgIHJlc3VsdFtrZXldID0gWyByZXN1bHRba2V5XSwgdmFsdWUgXVxuICAgICAgICB9XG4gICAgICB9XG4gIClcblxuICByZXR1cm4gcmVzdWx0XG59IiwiXG5leHBvcnRzID0gbW9kdWxlLmV4cG9ydHMgPSB0cmltO1xuXG5mdW5jdGlvbiB0cmltKHN0cil7XG4gIHJldHVybiBzdHIucmVwbGFjZSgvXlxccyp8XFxzKiQvZywgJycpO1xufVxuXG5leHBvcnRzLmxlZnQgPSBmdW5jdGlvbihzdHIpe1xuICByZXR1c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A9IDIwMFxuICAgICAgICB9IGVsc2Uge1xuICAgICAgICAgICAgc3RhdHVzID0gKHhoci5zdGF0dXMgPT09IDEyMjMgPyAyMDQgOiB4aHIuc3RhdHVzKVxuICAgICAgICB9XG4gICAgICAgIHZhciByZXNwb25zZSA9IGZhaWx1cmVSZXNwb25zZVxuICAgICAgICB2YXIgZXJyID0gbnVsbFxuXG4gICAgICAgIGlmIChzdGF0dXMgIT09IDApe1xuICAgICAgICAgICAgcmVzcG9uc2UgPSB7XG4gICAgICAgICAgICAgICAgYm9keTogZ2V0Qm9keSgpLFxuICAgICAgICAgICAgICAgIHN0YXR1c0NvZGU6IHN0YXR1cyxcbiAgICAgICAgICAgICAgICBtZXRob2Q6IG1ldGhvZCxcbiAgICAgICAgICAgICAgICBoZWFkZXJzOiB7fSxcbiAgICAgICAgICAgICAgICB1cmw6IHVyaSxcbiAgICAgICAgICAgICAgICByYXdSZXF1ZXN0OiB4aHJcbiAgICAgICAgICAgIH1cbiAgICAgICAgICAgIGlmKHhoci5nZXRBbGxSZXNwb25zZUhlYWRlcnMpeyAvL3JlbWVtYmVyIHhociBjYW4gaW4gZmFjdCBiZSBYRFIgZm9yIENPUlMgaW4gSUVcbiAgICAgICAgICAgICAgICByZXNwb25zZS5oZWFkZXJzID0gcGFyc2VIZWFkZXJzKHhoci5nZXRBbGxSZXNwb25zZUhlYWRlcnMoKSlcbiAgICAgICAgICAgIH1cbiAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgIGVyciA9IG5ldyBFcnJvcihcIkludGVybmFsIFhNTEh0dHBSZXF1ZXN0IEVycm9yXCIpXG4gICAgICAgIH1cbiAgICAgICAgY2FsbGJhY2soZXJyLCByZXNwb25zZSwgcmVzcG9uc2UuYm9keSlcblxuICAgIH1cblxuICAgIHZhciB4aHIgPSBvcHRpb25zLnhociB8fCBudWxsXG5cbiAgICBpZiAoIXhocikge1xuICAgICAgICBpZiAob3B0aW9ucy5jb3JzIHx8IG9wdGlvbnMudXNlW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lYXZlJywgKCkgPT4ge1xuICAgICAgICAgICAgICAgIG9uTGVhdmUodGhpcyk7XG4gICAgICAgICAgICB9KTtcbiAgICAgICAgfVxuXG4gICAgICAgIGlmICh0aGlzLm9wdGlvbnMub3BlbkZyYW1lSWNvbikge1xuICAgICAgICAgICAgdGhpcy5vcGVuRnJhbWVJY29uID0gbmV3IE9wZW5GcmFtZUljb24odGhpcyk7XG4gICAgICAgIH1cblxuICAgICAgICB0aGlzLmluaXQoKTtcbiAgICB9XG5cbiAgICBpbml0ICgpIHtcbiAgICAgICAgaWYgKCF0aGlzLnNvdXJjZSB8fCB0aGlzLnNvdXJjZSA9PT0gJycpIHtcbiAgICAgICAgICAgIHZhciB1cmwgPSAnJztcbiAgICAgICAgICAgIGlmICh0aGlzLmlkLm1hdGNoKC9cXGRcXGRcXC8uKi8pKSB7XG4gICAgICAgICAgICAgICAgdXJsID0gJ2h0dHA6Ly90aGVib29rb2ZzaGFkZXJzLmNvbS8nICsgdGhpcy5pZCArICcuZnJhZyc7XG4gICAgICAgICAgICB9XG4gICAgICAgICAgICBlbHNlIHtcbiAgICAgICAgICAgICAgICB1cmwgPSAnaHR0cDovL3RoZWJvb2tvZnNoYWRlcnMuY29tL2xvZy8nICsgdGhpcy5pZCArICcuZnJhZyc7XG4gICAgICAgICAgICB9XG4gICAgICAgICAgICBsZXQgaXRlbSA9IHRoaXM7XG4gICAgICAgICAgICB4aHIuZ2V0KHVybCwgKGVycm9yLCByZXMsIGJvZHkpID0+IHtcbiAgICAgICAgICAgICAgICBpZiAoZXJyb3IpIHtcbiAgICAgICAgICAgICAgICAgICAgY29uc29sZS5lcnJvcignRXJyb3IgZG93bmxvYWRpbmcgJywgZXJyb3IpO1xuICAgICAgICAgICAgICAgICAgICByZXR1cm47XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIGl0ZW0uc2V0Q29kZShib2R5KTtcbiAgICAgICAgICAgIH0pO1xuICAgICAgICB9XG4gICAgfVxuXG4gICAg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ZW0ubG9hZChpdGVtLmdldENvZGUoKSk7XG4gICAgfVxuICAgIGVsc2Uge1xuICAgICAgICB2YXIgdXJsID0gJyc7XG4gICAgICAgIGlmIChpdGVtLmlkLm1hdGNoKC9cXGRcXGRcXC8uKi8pKSB7XG4gICAgICAgICAgICB1cmwgPSAnaHR0cDovL3RoZWJvb2tvZnNoYWRlcnMuY29tLycgKyBpdGVtLmlkICsgJy5mcmFnJztcbiAgICAgICAgfVxuICAgICAgICBlbHNlIHtcbiAgICAgICAgICAgIHVybCA9ICdodHRwOi8vdGhlYm9va29mc2hhZGVycy5jb20vbG9nLycgKyBpdGVtLmlkICsgJy5mcmFnJztcbiAgICAgICAgfVxuXG4gICAgICAgIHhoci5nZXQodXJsLCAoZXJyb3IsIHJlcywgYm9keSkgPT4ge1xuICAgICAgICAgICAgaWYgKGVycm9yKSB7XG4gICAgICAgICAgICAgICAgY29uc29sZS5lcnJvcignRXJyb3IgZG93bmxvYWRpbmcgJywgZXJyb3IpO1xuICAgICAgICAgICAgICAgIHJldHVybjtcbiAgICAgICAgICAgIH1cbiAgICAgICAgICAgIGl0ZW0ubG9hZChib2R5KTtcbiAgICAgICAgfSk7XG4gICAgfVxufVxuXG5mdW5jdGlvbiBvbkxlYXZlIChpdGVtKSB7XG4gICAgaW5pdENhbnZhcygpO1xuXG4gICAgaWYgKGl0ZW0uZWwuZ2V0RWxlbWVudHNCeUNsYXNzTmFtZSgnZ2xzbEdhbGxlcnlfY2FudmFzJykgPiAwKSB7XG4gICAgICAgIC8vIFJlbW92ZSBnbHNsQ2FudmFzIGluc3RhbmNlIGZyb20gaXRlbVxuICAgICAgICBpdGVtLmVsLnJlbW92ZUNoaWxkKHdpbmRvdy5nbHNsR2FsbGVyeV9jYW52YXMuY2FudmFzKTtcbiAgICB9XG59XG4iLCIvKlxuVGhlIE1JVCBMaWNlbnNlIChNSVQpXG5cbkNvcHlyaWdodCAoYykgMjAxNiBQYXRyaWNpbyBHb256YWxleiBWaXZvICggaHR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ICB9XG5cbiAgICAgICAgdGhpcy5vcHRpb25zID0gb3B0aW9ucyB8fCB7fTtcblxuICAgICAgICBpZiAoIXRoaXMub3B0aW9ucy5zaG93QXV0aG9yKSB7XG4gICAgICAgICAgICB0aGlzLm9wdGlvbnMuc2hvd0F1dGhvciA9IHRydWU7XG4gICAgICAgIH1cblxuICAgICAgICBpZiAoIXRoaXMub3B0aW9ucy5zaG93VGl0bGUpIHtcbiAgICAgICAgICAgIHRoaXMub3B0aW9ucy5zaG93VGl0bGUgPSB0cnVlO1xuICAgICAgICB9XG5cbiAgICAgICAgaWYgKCF0aGlzLm9wdGlvbnMuaG92ZXJQcmV2aWV3KSB7XG4gICAgICAgICAgICB0aGlzLm9wdGlvbnMuaG92ZXJQcmV2aWV3ID0gdHJ1ZTtcbiAgICAgICAgfVxuXG4gICAgICAgIGlmICghdGhpcy5vcHRpb25zLm9wZW5GcmFtZUljb24pIHtcbiAgICAgICAgICAgIHRoaXMub3B0aW9ucy5vcGVuRnJhbWVJY29uID0gdHJ1ZTtcbiAgICAgICAgfVxuXG4gICAgICAgIGlmICghdGhpcy5vcHRpb25zLmNsaWNrUnVuKSB7XG4gICAgICAgICAgICB0aGlzLm9wdGlvbnMuY2xpY2tSdW4gPSAncGxheWVyJztcbiAgICAgICAgfVxuXG4gICAgICAgIHRoaXMuaXRlbXMgPSBbXTtcblxuICAgICAgICBpZiAoc2VsZWN0b3IuaGFzQXR0cmlidXRlKCdkYXRhLXByb3BlcnRpZXMnKSkge1xuICAgICAgICAgICAgbGV0IHByb3AgPSBzZWxlY3Rvci5nZXRBdHRyaWJ1dGUoJ2RhdGEtcHJvcGVydGllcycpLnNwbGl0KCcsJyk7XG4gICAgICAgICAgICBmb3IgKGxldCBpIGluIHByb3ApIHtcbiAgICAgICAgICAgICAgICBsZXQgdmFsdWVzID0gcHJvcFtpXS5zcGxpdCgnOicpO1xuICAgICAgICAgICAgICAgIGlmICh2YWx1ZXMubGVuZ3RoID09PSAxKSB7XG4gICA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DwtIHByb21pc2VcbiAgICAgIGM6IFtdLCAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAvLyA8LSBhd2FpdGluZyByZWFjdGlvbnNcbiAgICAgIGE6IHVuZGVmaW5lZCwgICAgICAgICAgICAgICAgICAgICAgICAgICAvLyA8LSBjaGVja2VkIGluIGlzVW5oYW5kbGVkIHJlYWN0aW9uc1xuICAgICAgczogMCwgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIC8vIDwtIHN0YXRlXG4gICAgICBkOiBmYWxzZSwgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgLy8gPC0gZG9uZVxuICAgICAgdjogdW5kZWZpbmVkLCAgICAgICAgICAgICAgICAgICAgICAgICAgIC8vIDwtIHZhbHVlXG4gICAgICBoOiBmYWxzZSwgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgLy8gPC0gaGFuZGxlZCByZWplY3Rpb25cbiAgICAgIG46IGZhbHNlICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAvLyA8LSBub3RpZnlcbiAgICB9O1xuICAgIHRyeSB7XG4gICAgICBleGVjdXRvcihjdHgoJHJlc29sdmUsIHJlY29yZCwgMSksIGN0eCgkcmVqZWN0LCByZWNvcmQsIDEpKTtcbiAgICB9IGNhdGNoKGVycil7XG4gICAgICAkcmVqZWN0LmNhbGwocmVjb3JkLCBlcnIpO1xuICAgIH1cbiAgfTtcbiAgcmVxdWlyZSgnLi8kLnJlZGVmaW5lLWFsbCcpKFAucHJvdG90eXBlLCB7XG4gICAgLy8gMjUuNC41LjMgUHJvbWlzZS5wcm90b3R5cGUudGhlbihvbkZ1bGZpbGxlZCwgb25SZWplY3RlZClcbiAgICB0aGVuOiBmdW5jdGlvbiB0aGVuKG9uRnVsZmlsbGVkLCBvblJlamVjdGVkKXtcbiAgICAgIHZhciByZWFjdGlvbiA9IG5ldyBQcm9taXNlQ2FwYWJpbGl0eShzcGVjaWVzQ29uc3RydWN0b3IodGhpcywgUCkpXG4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ZSA9PT0gNCkge1xuICAgICAgICAgICAgbG9hZEZ1bmMoKVxuICAgICAgICB9XG4gICAgfVxuXG4gICAgZnVuY3Rpb24gZ2V0Qm9keSgpIHtcbiAgICAgICAgLy8gQ2hyb21lIHdpdGggcmVxdWVzdFR5cGU9YmxvYiB0aHJvd3MgZXJyb3JzIGFycm91bmQgd2hlbiBldmVuIHRlc3RpbmcgYWNjZXNzIHRvIHJlc3BvbnNlVGV4dFxuICAgICAgICB2YXIgYm9keSA9IHVuZGVmaW5lZFxuXG4gICAgICAgIGlmICh4aHIucmVzcG9uc2UpIHtcbiAgICAgICAgICAgIGJvZHkgPSB4aHIucmVzcG9uc2VcbiAgICAgICAgfSBlbHNlIGlmICh4aHIucmVzcG9uc2VUeXBlID09PSBcInRleHRcIiB8fCAheGhyLnJlc3BvbnNlVHlwZSkge1xuICAgICAgICAgICAgYm9keSA9IHhoci5yZXNwb25zZVRleHQgfHwgeGhyLnJlc3BvbnNlWE1MXG4gICAgICAgIH1cblxuICAgICAgICBpZiAoaXNKc29uKSB7XG4gICAgICAgICAgICB0cnkge1xuICAgICAgICAgICAgICAgIGJvZHkgPSBKU09OLnBhcnNlKGJvZHkpXG4gICAgICAgICAgICB9IGNhdGNoIChlKSB7fVxuICAgICAgICB9XG5cbiAgICAgICAgcmV0dXJuIGJvZHlcbiAgICB9XG5cbiAgICB2YXIgZmFpbHVyZVJlc3BvbnNlID0ge1xuICAgICAgICAgICAgICAgIGJvZHk6IHVuZGVmaW5lZCxcbiAgICAgICAgICAgICAgICBoZWFkZXJzOiB7fSxcbiAgICAgICAgICAgICAgICBzdGF0dXNDb2RlOiAwLFxuICAgICAgICAgICAgICAgIG1ldGhvZDogbWV0aG9kLFxuICAgICAgICAgICAgICAgIHVybDogdXJpLFxuICAgICAgICAgICAgICAgIHJhd1JlcXVlc3Q6IHhoclxuICAgICAgICAgICAgfVxuXG4gICAgZnVuY3Rpb24gZXJyb3JGdW5jKGV2dCkge1xuICAgICAgICBjbGVhcl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FxuICAgICAgICAgICAgICAgIHN0YXR1c0NvZGU6IHN0YXR1cyxcbiAgICAgICAgICAgICAgICBtZXRob2Q6IG1ldGhvZCxcbiAgICAgICAgICAgICAgICBoZWFkZXJzOiB7fSxcbiAgICAgICAgICAgICAgICB1cmw6IHVyaSxcbiAgICAgICAgICAgICAgICByYXdSZXF1ZXN0OiB4aHJcbiAgICAgICAgICAgIH1cbiAgICAgICAgICAgIGlmKHhoci5nZXRBbGxSZXNwb25zZUhlYWRlcnMpeyAvL3JlbWVtYmVyIHhociBjYW4gaW4gZmFjdCBiZSBYRFIgZm9yIENPUlMgaW4gSUVcbiAgICAgICAgICAgICAgICByZXNwb25zZS5oZWFkZXJzID0gcGFyc2VIZWFkZXJzKHhoci5nZXRBbGxSZXNwb25zZUhlYWRlcnMoKSlcbiAgICAgICAgICAgIH1cbiAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgIGVyciA9IG5ldyBFcnJvcihcIkludGVybmFsIFhNTEh0dHBSZXF1ZXN0IEVycm9yXCIpXG4gICAgICAgIH1cbiAgICAgICAgY2FsbGJhY2soZXJyLCByZXNwb25zZSwgcmVzcG9uc2UuYm9keSlcblxuICAgIH1cblxuICAgIHZhciB4aHIgPSBvcHRpb25zLnhociB8fCBudWxsXG5cbiAgICBpZiAoIXhocikge1xuICAgICAgICBpZiAob3B0aW9ucy5jb3JzIHx8IG9wdGlvbnMudXNlWERSKSB7XG4gICAgICAgICAgICB4aHIgPSBuZXcgY3JlYXRlWEhSLlhEb21haW5SZXF1ZXN0KClcbiAgICAgICAgfWVsc2V7XG4gICAgICAgICAgICB4aHIgPSBuZXcgY3JlYXRlWEhSLlhNTEh0dHBSZXF1ZXN0KClcbiAgICAgICAgfVxuICAgIH1cblxuICAgIHZhciBrZXlcbiAgICB2YXIgYWJvcnRlZFxuICAgIHZhciB1cmkgPSB4aHIudXJsID0gb3B0aW9ucy51cmkgfHwgb3B0aW9ucy51cmxcbiAgICB2YXIgbWV0aG9kID0geGh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YXRhID0gbnVsbDtcbiAgICAgICAgdGhpcy52YWxpZCA9IGZhbHNlO1xuICAgIH1cblxuICAgIGJpbmQodW5pdCkge1xuICAgICAgICBpZiAoIXRoaXMudmFsaWQpIHtcbiAgICAgICAgICAgIHJldHVybjtcbiAgICAgICAgfVxuICAgICAgICBpZiAodHlwZW9mIHVuaXQgPT09ICdudW1iZXInKSB7XG4gICAgICAgICAgICBpZiAoVGV4dHVyZS5hY3RpdmVVbml0ICE9PSB1bml0KSB7XG4gICAgICAgICAgICAgICAgdGhpcy5nbC5hY3RpdmVUZXh0dXJlKHRoaXMuZ2wuVEVYVFVSRTAgKyB1bml0KTtcbiAgICAgICAgICAgICAgICBUZXh0dXJlLmFjdGl2ZVVuaXQgPSB1bml0O1xuICAgICAgICAgICAgfVxuICAgICAgICB9XG4gICAgICAgIGlmIChUZXh0dXJlLmFjdGl2ZVRleHR1cmUgIT09IHRoaXMudGV4dHVyZSkge1xuICAgICAgICAgICAgdGhpcy5nbC5iaW5kVGV4dHVyZSh0aGlzLmdsLlRFWFRVUkVfMkQsIHRoaXMudGV4dHVyZSk7XG4gICAgICAgICAgICBUZXh0dXJlLmFjdGl2ZVRleHR1cmUgPSB0aGlzLnRleHR1cmU7XG4gICAgICAgIH1cbiAgICB9XG5cbiAgICBsb2FkKG9wdGlvbnMgPSB7fSkge1xuICAgICAgICB0aGlzLmxvYWRpbmcgPSBudWxsO1xuXG4gICAgICAgIGlmICh0eXBlb2Ygb3B0aW9ucy51cmwgPT09ICdzdHJpbmcnKSB7XG4gICAgICAgICAgICB0aGlzLnNldFVybChvcHRpb25zLnVybCwgb3B0aW9ucyk7XG4gICAgICAgIH1cbiAgICAgICAgZWxzZSBpZiAob3B0aW9ucy5lbGVtZW50KSB7XG4gICAgICAgICAgICB0aGlzLnNldEVsZW1lbnQob3B0aW9ucy5lbGVtZW50LCBvcHRpb25zKTtcbiAgICAgICAgfVxuICAgICAgICBlbHNlIGlmIChvcHRpb25zLmRhdGEgJiYgb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AgICAgaWYgKHByZWZpeCkge1xuICAgICAgICAgICAgbmFtZSA9IHByZWZpeCArICcuJyArIG5hbWU7XG4gICAgICAgIH1cblxuICAgICAgICAvLyBTaW5nbGUgZmxvYXRcbiAgICAgICAgaWYgKHR5cGVvZiB1bmlmb3JtID09PSAnbnVtYmVyJykge1xuICAgICAgICAgICAgcGFyc2VkLnB1c2goe1xuICAgICAgICAgICAgICAgIHR5cGU6ICdmbG9hdCcsXG4gICAgICAgICAgICAgICAgbWV0aG9kOiAnMWYnLFxuICAgICAgICAgICAgICAgIG5hbWUsXG4gICAgICAgICAgICAgICAgdmFsdWU6IHVuaWZvcm1cbiAgICAgICAgICAgIH0pO1xuICAgICAgICB9XG4gICAgICAgIC8vIEFycmF5OiB2ZWN0b3IsIGFycmF5IG9mIGZsb2F0cywgYXJyYXkgb2YgdGV4dHVyZXMsIG9yIGFycmF5IG9mIHN0cnVjdHNcbiAgICAgICAgZWxzZSBpZiAoQXJyYXkuaXNBcnJheSh1bmlmb3JtKSkge1xuICAgICAgICAgICAgLy8gTnVtZXJpYyB2YWx1ZXNcbiAgICAgICAgICAgIGlmICh0eXBlb2YgdW5pZm9ybVswXSA9PT0gJ251bWJlcicpIHtcbiAgICAgICAgICAgICAgICAvLyBmbG9hdCB2ZWN0b3JzICh2ZWMyLCB2ZWMzLCB2ZWM0KVxuICAgICAgICAgICAgICAgIGlmICh1bmlmb3JtLmxlbmd0aCA9PT0gMSkge1xuICAgICAgICAgICAgICAgICAgICBwYXJzZWQucHVzaCh7XG4gICAgICAgICAgICAgICAgICAgICAgICB0eXBlOiAnZmxvYXQnLFxuICAgICAgICAgICAgICAgICAgICAgICAgbWV0aG9kOiAnMWYnLFxuICAgICAgICAgICAgICAgICAgICAgICAgbmFtZSxcbiAgICAgICAgICAgICAgICAgICAgICAgIHZhbHVlOiB1bmlmb3JtXG4gICAgICAgICAgICAgICAgICAgIH0pO1xuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICAvLyBmbG9hdCB2ZWN0b3JzICh2ZWMyLCB2ZWMzLCB2ZWM0KVxuICAgICAgICAgICAgICAgIGVsc2UgaWYgKHVuaWZvcm0ubGVuZ3RoID49IDIgJiYgdW5pZm9ybS5sZW5ndGggPD0gNCkge1xuICAgICAgICAgICAgICAgICAgICBwYXJzZWQucHVzaCh7XG4gICAgICAgICAgICAgICAgICAgICAgICB0eXBlOiAndmVjJyArIHVuaWZvcm0ubGVuZ3RoLFxuICAgICAgICAgICAgICAgICAgICAgICAgbWV0aG9kOiB1bmlmb3JtLmxlbmd0aCArICdmdicsXG4gICAgICAgICAgICAgICAgICAgICAgICBuYW1lLFxuICAgICAgICAgICAgICAgICAgICAgICAgdmFsdWU6IHVuaWZvcm1cbiAgICAgICAgICAgICAgICAgICAgfSk7XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIC8vIGZsb2F0IGFycmF5XG4gICAgICAgICAgICAgICAgZWxzZSBpZiAodW5pZm9ybS5sZW5ndGggPiA0KSB7XG4gICAgICAgICAgICAgICAgICAgIHBhcnNlZC5wdXNoKHtcbiAgICAgICAgICAgICAgICAgICAgICAgIHR5cGU6ICdmbG9hdFtdJyxcbiAgICAgICAgICAgICAgICAgICAgICAgIG1ldGhvZDogJzFmdicsXG4gICAgICAgICAgICAgICAgICAgICAgICBuYW1lOiBuYW1lICsgJ1swXScsXG4gICAgICAgICAgICAgICAgICAgICAgICB2YWx1ZTogdW5pZm9ybVxuICAgICAgICAgICAgICAgICAgICB9KTtcbiAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgLy8gVE9ETzogYXNzdW1lIG1hdHJpeCBmb3IgKHR5cGVvZiA9PSBGbG9hdDMyQXJyYXkgJiYgbGVuZ3RoID09IDE2KT9cbiAgICAgICAgICAgIH1cbiAgICAgICAgICAgIC8vIEFycmF5IG9mIHRleHR1cmVzXG4gICAgICAgICAgICBlbHNlIGlmICh0eXBlb2YgdW5pZm9ybVswXSA9PT0gJ3N0cmluZycpIHtcbiAgICAgICAgICAgICAgICBwYXJzZWQucHVzaCh7XG4gICAgICAgICAgICAgICAgICAgIHR5cGU6ICdzYW1wbGVyMkQnLFxuICAgICAgICAgICAgICAgICAgICBtZXRob2Q6ICcxaScsXG4gICAgICAgICAgICAgICAgICAgIG5hbWU6IG5hbWUsXG4gICAgICAgICAgICAgICAgICAgIHZhbHVlOiB1bmlmb3JtXG4gICAgICAgICAgICAgICAgfSk7XG4gICAgICAgICAgICB9XG4gICAgICAgICAgICAvLyBBcnJheSBvZiBhcnJheXMgLSBidXQgb25seSBhcnJheXMgb2YgdmVjdG9ycyBhcmUgYWxsb3dlZCBpbiB0aGlzIGNhc2VcbiAgICAgICAgICAgIGVsc2UgaWYgKEFycmF5LmlzQXJyYXkodW5pZm9ybVswXSkgJiYgdHlwZW9mIHVuaWZvcm1bMF1bMF0gPT09ICdudW1iZXInKSB7XG4gICAgICAgICAgICAgICAgLy8gZmxvYXQgdmVjdG9ycyAodmVjMiwgdmVjMywgdmVjNClcbiAgICAgICAgICAgICAgICBpZiAodW5pZm9ybVswXS5sZW5ndGggPj0gMiAmJiB1bmlmb3JtWzBdLmxlbmd0aCA8PSA0KSB7XG4gICAgICAgICAgICAgICAgICAgIC8vIFNldCBlYWNoIHZlY3RvciBpbiB0aGUgYXJyYXlcbiAgICAgICAgICAgICAgICAgICAgZm9yICh1ID0gMDsgdSA8IHVuaWZvcm0ubGVuZ3RoOyB1KyspIHtcbiAgICAgICAgICAgICAgICAgICAgICAgIHBhcnNlZC5wdXNoKHtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB0eXBlOiAndmVjJyArIHVuaWZvcm1bMF0ubGVuZ3RoLFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIG1ldGhvZDogdW5pZm9ybVt1XS5sZW5ndGggKyAnZnYnLFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIG5hbWU6IG5hbWUgKyAnWycgKyB1ICsgJ10nLFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHZhbHVlOiB1bmlmb3JtW3VdXG4gICAgICAgICAgICAgICAgICAgICAgICB9KTtcbiAgICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICAvLyBlbHNlIGVycm9yP1xuICAgICAgICAgICAgfVxuICAgICAgICAgICAgLy8gQXJyYXkgb2Ygc3RydWN0dXJlc1xuICAgICAgICAgICAgZWxzZSBpZiAodHlwZW9mIHVuaWZvcm1bMF0gPT09ICdvYmplY3QnKSB7XG4gICAgICAgICAgICAgICAgZm9yICh1ID0gMDsgdSA8IHVuaWZvcm0ubGVuZ3RoOyB1KyspIHtcbiAgICAgICAgICAgICAgICAgICAgLy8gU2V0IGVhY2ggc3RydWN0IGluIHRoZSBhcnJheVxuICAgICAgICAgICAgICAgICAgICBwYXJzZWQucHVzaCguLi5wYXJzZVVuaWZvcm1zKHVuaWZvcm1bdV0sIG5hbWUgKyAnWycgKyB1ICsgJ10nKSk7XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgfVxuICAgICAgICB9XG4gICAgICAgIC8vIEJvb2xlYW5cbiAgICAgICAgZWxzZSBpZiAodHlwZW9mIHVuaWZvcm0gPT09ICdib29sZWFuJykge1xuICAgICAgICAgICAgcGFyc2VkLnB1c2goe1xuICAgICAgICAgICAgICAgIHR5cGU6ICdib29sJyxcbiAgICAgICAgICAgICAgICBtZXRob2Q6ICcxaScsXG4gICAgICAgICAgICAgICAgbmFtZSxcbiAgICAgICAgICAgICAgICB2YWx1ZTogdW5pZm9ybVxuICAgICAgICAgICAgfSk7XG4gICAgICAgIH1cbiAgICAgICAgLy8gVGV4dHVyZVxuICAgICAgICBlbHNlIGlmICh0eXBlb2YgdW5pZm9ybSA9PT0gJ3N0cmluZycpIHtcbiAgICAgICAgICAgIHBhcnNlZC5wdXNoKHtcbiAgICAgICAgICAgICAgICB0eXBlOiAnc2FtcGxlcjJEJyxcbiAgICAgICAgICAgICAgICBtZXRob2Q6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KGxpc3RlbmVyKSB7XG4gICAgICAgICAgICBsaXN0ZW5lcnMuZGVsZXRlKGxpc3RlbmVyKTtcbiAgICAgICAgfSxcblxuICAgICAgICB1bnN1YnNjcmliZUFsbCgpIHtcbiAgICAgICAgICAgIGxpc3RlbmVycy5jbGVhcigpO1xuICAgICAgICB9LFxuXG4gICAgICAgIHRyaWdnZXIoZXZlbnQsIC4uLmRhdGEpIHtcbiAgICAgICAgICAgIGZvciAodmFyIGxpc3RlbmVyIG9mIGxpc3RlbmVycykge1xuICAgICAgICAgICAgICAgIGlmICh0eXBlb2YgbGlzdGVuZXJbZXZlbnRdID09PSAnZnVuY3Rpb24nKSB7XG4gICAgICAgICAgICAgICAgICAgIGxpc3RlbmVyW2V2ZW50XSguLi5kYXRhKTtcbiAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICB9XG4gICAgICAgIH1cbiAgICB9KTtcbn1cbiIsImV4cG9ydCBmdW5jdGlvbiBzdWJzY3JpYmVNaXhpbiAodGFyZ2V0KSB7XG4gICAgdmFyIGxpc3RlbmVycyA9IG5ldyBTZXQoKTtcblxuICAgIHJldHVybiBPYmplY3QuYXNzaWduKHRhcmdldCwge1xuXG4gICAgICAgIG9uKHR5cGUsIGYpIHtcbiAgICAgICAgICAgIGxldCBsaXN0ZW5lciA9IHt9O1xuICAgICAgICAgICAgbGlzdGVuZXJbdHlwZV0gPSBmO1xuICAgICAgICAgICAgbGlzdGVuZXJzLmFkZChsaXN0ZW5lcik7XG4gICAgICAgIH0sXG5cbiAgICAgICAgb2ZmKHR5cGUsIGYpIHtcbiAgICAgICAgICAgIGlmIChmKSB7XG4gICAgICAgICAgICAgICAgbGV0IGxpc3RlbmVyID0ge307XG4gICAgICAgICAgICAgICAgbGlzdGVuZXJbdHlwZV0gPSBmO1xuICAgICAgICAgICAgICAgIGxpc3RlbmVycy5kZWxldGUobGlzdGVuZXIpO1xuICAgICAgICAgICAgfVxuICAgICAgICAgICAgZWxzZSB7XG4gICAgICAgICAgICAgICAgZm9yIChsZXQgaXRlbSBvZiBsaXN0ZW5lcnMpIHtcbiAgICAgICAgICAgICAgICAgICAgZm9yIChsZXQga2V5IG9mIE9iamVjdC5rZXlzKGl0ZW0pKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICBpZiAoa2V5ID09PSB0eXBlKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgbGlzdGVuZXJzLmRlbGV0ZShpdGVtKTtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm47XG4gICAgICAgICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICB9XG4gICAgICAgIH0sXG5cbiAgICAgICAgbGlzdFN1YnNjcmlwdGlvbnMoKSB7XG4gICAgICAgICAgICBmb3IgKGxldCBpdGVtIG9mIGxpc3RlbmVycykge1xuICAgICAgICAgICAgICAgIGNvbnNvbGUubG9nKGl0ZW0pO1xuICAgICAgICAgICAgfVxuICAgICAgICB9LFxuXG4gICAgICAgIHN1YnNjcmliZShsaXN0ZW5lcikge1xuICAgICAgICAgICAgbGlzdGVuZXJzLmFkZChsaXN0ZW5lcik7XG4gICAgICAgIH0sXG5cbiAgICAgICAgdW5zdWJzY3JpYmUobGlzdGVuZXIpIHtcbiAgICAgICAgICAgIGxpc3RlbmVycy5kZWxldGUobGlzdGVuZXIpO1xuICAgICAgICB9LFxuXG4gICAgICAgIHVuc3Vic2NyaWJlQWxsKCkge1xuICAgICAgICAgICAgbGlzdGVuZXJzLmNsZWFyKCk7XG4gICAgICAgIH0sXG5cbiAgICAgICAgdHJpZ2dlcihldmVudCwgLi4uZGF0YSkge1xuICAgICAgICAgICAgZm9yICh2YXIgbGlzdGVuZXIgb2YgbGlzdGVuZXJzKSB7XG4gICAgICAgICAgICAgICAgaWYgKHR5cGVvZiBsaXN0ZW5lcltldmVudF0gPT09ICdmdW5jdGlvbicpIHtcbiAgICAgICAgICAgICAgICAgICAg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ZSA9PT0gNCkge1xuICAgICAgICAgICAgbG9hZEZ1bmMoKVxuICAgICAgICB9XG4gICAgfVxuXG4gICAgZnVuY3Rpb24gZ2V0Qm9keSgpIHtcbiAgICAgICAgLy8gQ2hyb21lIHdpdGggcmVxdWVzdFR5cGU9YmxvYiB0aHJvd3MgZXJyb3JzIGFycm91bmQgd2hlbiBldmVuIHRlc3RpbmcgYWNjZXNzIHRvIHJlc3BvbnNlVGV4dFxuICAgICAgICB2YXIgYm9keSA9IHVuZGVmaW5lZFxuXG4gICAgICAgIGlmICh4aHIucmVzcG9uc2UpIHtcbiAgICAgICAgICAgIGJvZHkgPSB4aHIucmVzcG9uc2VcbiAgICAgICAgfSBlbHNlIGlmICh4aHIucmVzcG9uc2VUeXBlID09PSBcInRleHRcIiB8fCAheGhyLnJlc3BvbnNlVHlwZSkge1xuICAgICAgICAgICAgYm9keSA9IHhoci5yZXNwb25zZVRleHQgfHwgeGhyLnJlc3BvbnNlWE1MXG4gICAgICAgIH1cblxuICAgICAgICBpZiAoaXNKc29uKSB7XG4gICAgICAgICAgICB0cnkge1xuICAgICAgICAgICAgICAgIGJvZHkgPSBKU09OLnBhcnNlKGJvZHkpXG4gICAgICAgICAgICB9IGNhdGNoIChlKSB7fVxuICAgICAgICB9XG5cbiAgICAgICAgcmV0dXJuIGJvZHlcbiAgICB9XG5cbiAgICB2YXIgZmFpbHVyZVJlc3BvbnNlID0ge1xuICAgICAgICAgICAgICAgIGJvZHk6IHVuZGVmaW5lZCxcbiAgICAgICAgICAgICAgICBoZWFkZXJzOiB7fSxcbiAgICAgICAgICAgICAgICBzdGF0dXNDb2RlOiAwLFxuICAgICAgICAgICAgICAgIG1ldGhvZDogbWV0aG9kLFxuICAgICAgICAgICAgICAgIHVybDogdXJpLFxuICAgICAgICAgICAgICAgIHJhd1JlcXVlc3Q6IHhoclxuICAgICAgICAgICAgfVxuXG4gICAgZnVuY3Rpb24gZXJyb3JGdW5jKGV2dCkge1xuICAgICAgICBjbGVh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LFxuICAgICAgICAgICAgICAgIHN0YXR1c0NvZGU6IHN0YXR1cyxcbiAgICAgICAgICAgICAgICBtZXRob2Q6IG1ldGhvZCxcbiAgICAgICAgICAgICAgICBoZWFkZXJzOiB7fSxcbiAgICAgICAgICAgICAgICB1cmw6IHVyaSxcbiAgICAgICAgICAgICAgICByYXdSZXF1ZXN0OiB4aHJcbiAgICAgICAgICAgIH1cbiAgICAgICAgICAgIGlmKHhoci5nZXRBbGxSZXNwb25zZUhlYWRlcnMpeyAvL3JlbWVtYmVyIHhociBjYW4gaW4gZmFjdCBiZSBYRFIgZm9yIENPUlMgaW4gSUVcbiAgICAgICAgICAgICAgICByZXNwb25zZS5oZWFkZXJzID0gcGFyc2VIZWFkZXJzKHhoci5nZXRBbGxSZXNwb25zZUhlYWRlcnMoKSlcbiAgICAgICAgICAgIH1cbiAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgIGVyciA9IG5ldyBFcnJvcihcIkludGVybmFsIFhNTEh0dHBSZXF1ZXN0IEVycm9yXCIpXG4gICAgICAgIH1cbiAgICAgICAgY2FsbGJhY2soZXJyLCByZXNwb25zZSwgcmVzcG9uc2UuYm9keSlcblxuICAgIH1cblxuICAgIHZhciB4aHIgPSBvcHRpb25zLnhociB8fCBudWxsXG5cbiAgICBpZiAoIXhocikge1xuICAgICAgICBpZiAob3B0aW9ucy5jb3JzIHx8IG9wdGlvbnMudXNlWERSKSB7XG4gICAgICAgICAgICB4aHIgPSBuZXcgY3JlYXRlWEhSLlhEb21haW5SZXF1ZXN0KClcbiAgICAgICAgfWVsc2V7XG4gICAgICAgICAgICB4aHIgPSBuZXcgY3JlYXRlWEhSLlhNTEh0dHBSZXF1ZXN0KClcbiAgICAgICAgfVxuICAgIH1cblxuICAgIHZhciBrZXlcbiAgICB2YXIgYWJvcnRlZFxuICAgIHZhciB1cmkgPSB4aHIudXJsID0gb3B0aW9ucy51cmkgfHwgb3B0aW9ucy51cmxcbiAgICB2YXIgbWV0aG9kID0geG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0aGlzLnNvdXJjZSB8fCB0aGlzLnNvdXJjZSA9PT0gJycpIHtcbiAgICAgICAgICAgIHZhciB1cmwgPSAnJztcbiAgICAgICAgICAgIGlmICh0aGlzLmlkLm1hdGNoKC9cXGRcXGRcXC8uKi8pKSB7XG4gICAgICAgICAgICAgICAgdXJsID0gJ2h0dHA6Ly90aGVib29rb2ZzaGFkZXJzLmNvbS8nICsgdGhpcy5pZCArICcuZnJhZyc7XG4gICAgICAgICAgICB9XG4gICAgICAgICAgICBlbHNlIHtcbiAgICAgICAgICAgICAgICB1cmwgPSAnaHR0cDovL3RoZWJvb2tvZnNoYWRlcnMuY29tL2xvZy8nICsgdGhpcy5pZCArICcuZnJhZyc7XG4gICAgICAgICAgICB9XG4gICAgICAgICAgICBsZXQgaXRlbSA9IHRoaXM7XG4gICAgICAgICAgICB4aHIuZ2V0KHVybCwgKGVycm9yLCByZXMsIGJvZHkpID0+IHtcbiAgICAgICAgICAgICAgICBpZiAoZXJyb3IpIHtcbiAgICAgICAgICAgICAgICAgICAgY29uc29sZS5lcnJvcignRXJyb3IgZG93bmxvYWRpbmcgJywgZXJyb3IpO1xuICAgICAgICAgICAgICAgICAgICByZXR1cm47XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIGl0ZW0uc2V0Q29kZShib2R5KTtcbiAgICAgICAgICAgIH0pO1xuICAgICAgICB9XG4gICAgfVxuXG4gICAgbG9hZCAoY29kZSkge1xuICAgICAgICB0aGlzLnNldENvZGUoY29kZSk7XG4gICAgICAgIHdpbmRvdy5nbHNsR2FsbGVyeV9jYW52YXMubG9hZChjb2RlKTtcbiAgICAgICAgd2luZG93Lmdsc2xHYWxsZXJ5X2NhbnZhcy5jYW52YXMuc3R5bGUuaGVpZ2h0ID0gdGhpcy5pbWcub2Zmc2V0SGVpZ2h0ICsgJ3B4JztcbiAgICAgICAgdGhpcy5saW5rLmFwcGVuZENoaWxkKHdpbmRvdy5nbHNsR2FsbGVyeV9jYW52YXMuY2F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