├── .gitignore ├── LICENSE ├── README.md ├── app.html ├── app.js ├── app.js.map ├── app.ts ├── favicon.ico ├── index.html ├── lib ├── angular2.d.ts ├── angular2.dev.js ├── angular2.sfx.dev.js ├── es6-module-loader@0.16.6.js ├── system@0.16.11.js └── traceur-runtime.js ├── login.html ├── shell.html └── tsconfig.json /.gitignore: -------------------------------------------------------------------------------- 1 | node_modules/ 2 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2015 Miško Hevery 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | 23 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # angular-u-app 2 | -------------------------------------------------------------------------------- /app.html: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /app.js: -------------------------------------------------------------------------------- 1 | if (typeof __decorate !== "function") __decorate = function (decorators, target, key, desc) { 2 | if (typeof Reflect === "object" && typeof Reflect.decorate === "function") return Reflect.decorate(decorators, target, key, desc); 3 | switch (arguments.length) { 4 | case 2: return decorators.reduceRight(function(o, d) { return (d && d(o)) || o; }, target); 5 | case 3: return decorators.reduceRight(function(o, d) { return (d && d(target, key)), void 0; }, void 0); 6 | case 4: return decorators.reduceRight(function(o, d) { return (d && d(target, key, o)) || o; }, desc); 7 | } 8 | }; 9 | if (typeof __metadata !== "function") __metadata = function (k, v) { 10 | if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v); 11 | }; 12 | var angular2_1 = require("angular2/angular2"); 13 | var Login = (function () { 14 | function Login() { 15 | this.success = new angular2_1.EventEmitter(); 16 | this.username = 'misko'; 17 | this.password = ''; 18 | } 19 | Login.prototype.login = function () { 20 | if (this.password == '123') { 21 | this.success.next(this.username); 22 | } 23 | }; 24 | Login = __decorate([ 25 | angular2_1.Component({ 26 | selector: 'login', 27 | events: ['success'] 28 | }), 29 | angular2_1.View({ 30 | templateUrl: 'login.html', 31 | directives: [angular2_1.formDirectives] 32 | }), 33 | __metadata('design:paramtypes', []) 34 | ], Login); 35 | return Login; 36 | })(); 37 | var Shell = (function () { 38 | function Shell() { 39 | } 40 | Shell = __decorate([ 41 | angular2_1.Component({ 42 | selector: 'shell', 43 | properties: ['user'] 44 | }), 45 | angular2_1.View({ 46 | templateUrl: 'shell.html' 47 | }), 48 | __metadata('design:paramtypes', []) 49 | ], Shell); 50 | return Shell; 51 | })(); 52 | var AngularUApp = (function () { 53 | function AngularUApp() { 54 | this.username = null; 55 | } 56 | AngularUApp = __decorate([ 57 | angular2_1.Component({ 58 | selector: 'angular-u-app' 59 | }), 60 | angular2_1.View({ 61 | templateUrl: 'app.html', 62 | directives: [Login, Shell, angular2_1.NgIf] 63 | }), 64 | __metadata('design:paramtypes', []) 65 | ], AngularUApp); 66 | return AngularUApp; 67 | })(); 68 | angular2_1.bootstrap(AngularUApp); 69 | //# sourceMappingURL=app.js.map -------------------------------------------------------------------------------- /app.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"app.js","sourceRoot":"","sources":["app.ts"],"names":["Login","Login.constructor","Login.login","Shell","Shell.constructor","AngularUApp","AngularUApp.constructor"],"mappings":";;;;;;;;;;;AAAA,yBAA6E,mBAAmB,CAAC,CAAA;AAEjG;IAAAA;QASEC,YAAOA,GAAGA,IAAIA,uBAAYA,EAAEA,CAACA;QAC7BA,aAAQA,GAAWA,OAAOA,CAACA;QAC3BA,aAAQA,GAAWA,EAAEA,CAACA;IAOxBA,CAACA;IALCD,qBAAKA,GAALA;QACEE,EAAEA,CAACA,CAACA,IAAIA,CAACA,QAAQA,IAAIA,KAAKA,CAACA,CAACA,CAACA;YAC3BA,IAAIA,CAACA,OAAOA,CAACA,IAAIA,CAACA,IAAIA,CAACA,QAAQA,CAACA,CAACA;QACnCA,CAACA;IACHA,CAACA;IAjBHF;QAACA,oBAASA,CAACA;YACTA,QAAQA,EAAEA,OAAOA;YACjBA,MAAMA,EAAEA,CAACA,SAASA,CAACA;SACpBA,CAACA;QACDA,eAAIA,CAACA;YACJA,WAAWA,EAAEA,YAAYA;YACzBA,UAAUA,EAAEA,CAACA,yBAAcA,CAACA;SAC7BA,CAACA;;cAWDA;IAADA,YAACA;AAADA,CAACA,AAlBD,IAkBC;AAED;IAAAG;IASAC,CAACA;IATDD;QAACA,oBAASA,CAACA;YACTA,QAAQA,EAAEA,OAAOA;YACjBA,UAAUA,EAAEA,CAACA,MAAMA,CAACA;SACrBA,CAACA;QACDA,eAAIA,CAACA;YACJA,WAAWA,EAAEA,YAAYA;SAC1BA,CAACA;;cAGDA;IAADA,YAACA;AAADA,CAACA,AATD,IASC;AAED;IASEE;QADAC,aAAQA,GAAGA,IAAIA,CAACA;IAEhBA,CAACA;IAVHD;QAACA,oBAASA,CAACA;YACTA,QAAQA,EAAEA,eAAeA;SAC1BA,CAACA;QACDA,eAAIA,CAACA;YACJA,WAAWA,EAAEA,UAAUA;YACvBA,UAAUA,EAAEA,CAACA,KAAKA,EAAEA,KAAKA,EAAEA,eAAIA,CAACA;SACjCA,CAACA;;oBAKDA;IAADA,kBAACA;AAADA,CAACA,AAXD,IAWC;AAGD,oBAAS,CAAC,WAAW,CAAC,CAAC"} -------------------------------------------------------------------------------- /app.ts: -------------------------------------------------------------------------------- 1 | import {Component, View, bootstrap, formDirectives, EventEmitter, NgIf} from "angular2/angular2"; 2 | 3 | @Component({ 4 | selector: 'login', 5 | events: ['success'] 6 | }) 7 | @View({ 8 | templateUrl: 'login.html', 9 | directives: [formDirectives] 10 | }) 11 | class Login { 12 | success = new EventEmitter(); 13 | username: string = 'misko'; 14 | password: string = ''; 15 | 16 | login() { 17 | if (this.password == '123') { 18 | this.success.next(this.username); 19 | } 20 | } 21 | } 22 | 23 | @Component({ 24 | selector: 'shell', 25 | properties: ['user'] 26 | }) 27 | @View({ 28 | templateUrl: 'shell.html' 29 | }) 30 | class Shell { 31 | user:string; 32 | } 33 | 34 | @Component({ 35 | selector: 'angular-u-app' 36 | }) 37 | @View({ 38 | templateUrl: 'app.html', 39 | directives: [Login, Shell, NgIf] 40 | }) 41 | class AngularUApp { 42 | username = null; 43 | constructor() { 44 | } 45 | } 46 | 47 | 48 | bootstrap(AngularUApp); 49 | -------------------------------------------------------------------------------- /favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhevery/angular-u-app/551f7c6bd3d0f7dd167a045b79327df8b46f519a/favicon.ico -------------------------------------------------------------------------------- /index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | AngularU: App 4 | 5 | 6 | 7 | 13 | 14 | 15 | Loading... 16 | 17 | 18 | -------------------------------------------------------------------------------- /lib/angular2.d.ts: -------------------------------------------------------------------------------- 1 | 2 | declare module ng { 3 | class StringMap {} 4 | 5 | function bootstrap(type: Function); 6 | var Component: ComponentFactory; 7 | var View: ViewFactory; 8 | var formDirectives: Array 9 | 10 | interface Annotation {} 11 | 12 | interface ComponentFactory { 13 | new (args: ComponentArgs): Component; 14 | (args: ComponentArgs): ComponentDecorator 15 | } 16 | 17 | interface Decorator { 18 | Class: ClassFactory; 19 | annotations: Array; 20 | } 21 | 22 | interface ComponentDecorator extends Decorator { 23 | (type: T): T; 24 | View: ViewFactory; 25 | } 26 | 27 | interface ComponentArgs { 28 | selector?: string; 29 | properties?: Array; 30 | events?: Array; 31 | host?: StringMap; 32 | lifecycle?: Array; 33 | hostInjector?: Array; 34 | exportAs?: string; 35 | compileChildren?: boolean; 36 | } 37 | 38 | interface LifecycleEvent {} 39 | 40 | interface Component extends Annotation, ComponentArgs { 41 | 42 | } 43 | 44 | interface ViewFactory { 45 | new (args: ViewArgs): View; 46 | (args: ViewArgs): ViewDecorator 47 | } 48 | 49 | interface ViewDecorator extends Decorator { 50 | (type: T): T; 51 | } 52 | 53 | interface ViewArgs { 54 | templateUrl?: string; 55 | template?: string; 56 | directives?: Array>; 57 | renderer?: string; 58 | styles?: Array; 59 | styleUrls?: Array; 60 | } 61 | 62 | interface View extends Annotation, ViewArgs { 63 | 64 | } 65 | 66 | interface ClassFactory { 67 | (methods: { 68 | constructor: (Function | Array); 69 | extends?: Function 70 | }) 71 | } 72 | 73 | class Observable { 74 | observer(generator: any): Object; 75 | } 76 | 77 | class EventEmitter extends Observable { 78 | next(value):any; 79 | throw(error):any; 80 | return(value?):any; 81 | } 82 | } 83 | 84 | 85 | declare module "angular2/angular2" { 86 | export = ng; 87 | } 88 | -------------------------------------------------------------------------------- /lib/es6-module-loader@0.16.6.js: -------------------------------------------------------------------------------- 1 | !function(e){"object"==typeof exports?module.exports=e():"function"==typeof define&&define.amd?define(e):"undefined"!=typeof window?window.Promise=e():"undefined"!=typeof global?global.Promise=e():"undefined"!=typeof self&&(self.Promise=e())}(function(){var e;return function t(e,n,o){function r(a,s){if(!n[a]){if(!e[a]){var u="function"==typeof require&&require;if(!s&&u)return u(a,!0);if(i)return i(a,!0);throw new Error("Cannot find module '"+a+"'")}var l=n[a]={exports:{}};e[a][0].call(l.exports,function(t){var n=e[a][1][t];return r(n?n:t)},l,l.exports,t,e,n,o)}return n[a].exports}for(var i="function"==typeof require&&require,a=0;a=0&&(p.splice(t,1),d("Handled previous rejection ["+e.id+"] "+r.formatObject(e.value)))}function s(e,t){f.push(e,t),null===h&&(h=o(u,0))}function u(){for(h=null;f.length>0;)f.shift()(f.shift())}var l,c=n,d=n;"undefined"!=typeof console&&(l=console,c="undefined"!=typeof l.error?function(e){l.error(e)}:function(e){l.log(e)},d="undefined"!=typeof l.info?function(e){l.info(e)}:function(e){l.log(e)}),e.onPotentiallyUnhandledRejection=function(e){s(i,e)},e.onPotentiallyUnhandledRejectionHandled=function(e){s(a,e)},e.onFatalRejection=function(e){s(t,e.value)};var f=[],p=[],h=null;return e}})}("function"==typeof e&&e.amd?e:function(e){n.exports=e(t)})},{"../env":5,"../format":6}],5:[function(t,n){!function(e){"use strict";e(function(e){function t(){return"undefined"!=typeof process&&null!==process&&"function"==typeof process.nextTick}function n(){return"function"==typeof MutationObserver&&MutationObserver||"function"==typeof WebKitMutationObserver&&WebKitMutationObserver}function o(e){function t(){var e=n;n=void 0,e()}var n,o=document.createTextNode(""),r=new e(t);r.observe(o,{characterData:!0});var i=0;return function(e){n=e,o.data=i^=1}}var r,i="undefined"!=typeof setTimeout&&setTimeout,a=function(e,t){return setTimeout(e,t)},s=function(e){return clearTimeout(e)},u=function(e){return i(e,0)};if(t())u=function(e){return process.nextTick(e)};else if(r=n())u=o(r);else if(!i){var l=e,c=l("vertx");a=function(e,t){return c.setTimer(t,e)},s=c.cancelTimer,u=c.runOnLoop||c.runOnContext}return{setTimer:a,clearTimer:s,asap:u}})}("function"==typeof e&&e.amd?e:function(e){n.exports=e(t)})},{}],6:[function(t,n){!function(e){"use strict";e(function(){function e(e){var n="object"==typeof e&&null!==e&&e.stack?e.stack:t(e);return e instanceof Error?n:n+" (WARNING: non-Error used)"}function t(e){var t=String(e);return"[object Object]"===t&&"undefined"!=typeof JSON&&(t=n(e,t)),t}function n(e,t){try{return JSON.stringify(e)}catch(n){return t}}return{formatError:e,formatObject:t,tryStringify:n}})}("function"==typeof e&&e.amd?e:function(e){n.exports=e()})},{}],7:[function(t,n){!function(e){"use strict";e(function(){return function(e){function t(e,t){this._handler=e===g?t:n(e)}function n(e){function t(e){r.resolve(e)}function n(e){r.reject(e)}function o(e){r.notify(e)}var r=new w;try{e(t,n,o)}catch(i){n(i)}return r}function o(e){return M(e)?e:new t(g,new j(v(e)))}function r(e){return new t(g,new j(new E(e)))}function i(){return Z}function a(){return new t(g,new w)}function s(e,t){var n=new w(e.receiver,e.join().context);return new t(g,n)}function u(e){return c(F,null,e)}function l(e,t){return c(A,e,t)}function c(e,n,o){function r(t,r,a){a.resolved||d(o,i,t,e(n,r,t),a)}function i(e,t,n){c[e]=t,0===--l&&n.become(new O(c))}for(var a,s="function"==typeof n?r:i,u=new w,l=o.length>>>0,c=new Array(l),f=0;f0?t(n,i.value,r):(r.become(i),f(e,n+1,i))}else t(n,o,r)}function f(e,t,n){for(var o=t;on&&e._unreport()}}function h(e){return"object"!=typeof e||null===e?r(new TypeError("non-iterable passed to race()")):0===e.length?i():1===e.length?o(e[0]):m(e)}function m(e){var n,o,r,i=new w;for(n=0;n0||"function"!=typeof t&&0>r)return new this.constructor(g,o);var i=this._beget(),a=i._handler;return o.chain(a,o.receiver,e,t,n),i},t.prototype["catch"]=function(e){return this.then(void 0,e)},t.prototype._beget=function(){return s(this._handler,this.constructor)},t.all=u,t.race=h,t._traverse=l,t._visitRemaining=f,g.prototype.when=g.prototype.become=g.prototype.notify=g.prototype.fail=g.prototype._unreport=g.prototype._report=X,g.prototype._state=0,g.prototype.state=function(){return this._state},g.prototype.join=function(){for(var e=this;void 0!==e.handler;)e=e.handler;return e},g.prototype.chain=function(e,t,n,o,r){this.when({resolver:e,receiver:t,fulfilled:n,rejected:o,progress:r})},g.prototype.visit=function(e,t,n,o){this.chain(K,e,t,n,o)},g.prototype.fold=function(e,t,n,o){this.when(new q(e,t,n,o))},z(g,b),b.prototype.become=function(e){e.fail()};var K=new b;z(g,w),w.prototype._state=0,w.prototype.resolve=function(e){this.become(v(e))},w.prototype.reject=function(e){this.resolved||this.become(new E(e))},w.prototype.join=function(){if(!this.resolved)return this;for(var e=this;void 0!==e.handler;)if(e=e.handler,e===this)return this.handler=R();return e},w.prototype.run=function(){var e=this.consumers,t=this.handler;this.handler=this.handler.join(),this.consumers=void 0;for(var n=0;ni;i++)if(r=t.loads[i],r.name==n)return console.assert("loading"==r.status||"loaded"==r.status,"loading or loaded"),r;return r=e(n),t.loads.push(r),o(t,r),r})}function o(e,t){r(e,t,P.resolve().then(function(){return e.loaderObj.locate({name:t.name,metadata:t.metadata})}))}function r(e,t,n){i(e,t,n.then(function(n){return"loading"==t.status?(t.address=n,e.loaderObj.fetch({name:t.name,metadata:t.metadata,address:n})):void 0}))}function i(e,t,o){o.then(function(o){return"loading"==t.status?P.resolve(e.loaderObj.translate({name:t.name,metadata:t.metadata,address:t.address,source:o})).then(function(n){return t.source=n,e.loaderObj.instantiate({name:t.name,metadata:t.metadata,address:t.address,source:n})}).then(function(n){if(void 0===n)return t.address=t.address||"",t.isDeclarative=!0,e.loaderObj.transpile(t).then(function(e){var n=__global.System,o=n.register;n.register=function(e,n,o){"string"!=typeof e&&(o=n,n=e),t.declare=o,t.depsList=n},__eval(e,__global,t),n.register=o});if("object"!=typeof n)throw TypeError("Invalid instantiate return value");t.depsList=n.deps||[],t.execute=n.execute,t.isDeclarative=!1}).then(function(){t.dependencies=[];for(var o=t.depsList,r=[],i=0,a=o.length;a>i;i++)(function(o,i){r.push(n(e,o,t.name,t.address).then(function(e){if(t.dependencies[i]={key:o,value:e.name},"linked"!=e.status)for(var n=t.linkSets.concat([]),r=0,a=n.length;a>r;r++)u(n[r],e)}))})(o[i],i);return P.all(r)}).then(function(){console.assert("loading"==t.status,"is loading"),t.status="loaded";for(var e=t.linkSets.concat([]),n=0,o=e.length;o>n;n++)c(e[n],t)}):void 0})["catch"](function(e){t.status="failed",t.exception=e;for(var n=t.linkSets.concat([]),o=0,r=n.length;r>o;o++)d(n[o],t,e);console.assert(0==t.linkSets.length,"linkSets not removed")})}function a(t){return function(n){var a=t.loader,u=t.moduleName,l=t.step;if(a.modules[u])throw new TypeError('"'+u+'" already exists in the module table');for(var c,d=0,f=a.loads.length;f>d;d++)if(a.loads[d].name==u)return c=a.loads[d],"translate"!=l||c.source||(c.address=t.moduleAddress,i(a,c,P.resolve(t.moduleSource))),c.linkSets[0].done.then(function(){n(c)});var p=e(u);p.metadata=t.moduleMetadata;var h=s(a,p);a.loads.push(p),n(h.done),"locate"==l?o(a,p):"fetch"==l?r(a,p,P.resolve(t.moduleAddress)):(console.assert("translate"==l,"translate step"),p.address=t.moduleAddress,i(a,p,P.resolve(t.moduleSource)))}}function s(e,t){var n={loader:e,loads:[],startingLoad:t,loadingCount:0};return n.done=new P(function(e,t){n.resolve=e,n.reject=t}),u(n,t),n}function u(e,t){console.assert("loading"==t.status||"loaded"==t.status,"loading or loaded on link set");for(var n=0,o=e.loads.length;o>n;n++)if(e.loads[n]==t)return;e.loads.push(t),t.linkSets.push(e),"loaded"!=t.status&&e.loadingCount++;for(var r=e.loader,n=0,o=t.dependencies.length;o>n;n++){var i=t.dependencies[n].value;if(!r.modules[i])for(var a=0,s=r.loads.length;s>a;a++)if(r.loads[a].name==i){u(e,r.loads[a]);break}}}function l(e){var t=!1;try{m(e,function(n,o){d(e,n,o),t=!0})}catch(n){d(e,null,n),t=!0}return t}function c(e,t){if(console.assert("loaded"==t.status||"linked"==t.status,"loaded or linked"),e.loadingCount--,!(e.loadingCount>0)){var n=e.startingLoad;if(e.loader.loaderObj.execute===!1){for(var o=[].concat(e.loads),r=0,i=o.length;i>r;r++){var t=o[r];t.module=t.isDeclarative?{name:t.name,module:T({}),evaluated:!0}:{module:T({})},t.status="linked",f(e.loader,t)}return e.resolve(n)}var a=l(e);a||(console.assert(0==e.loads.length,"loads cleared"),e.resolve(n))}}function d(e,t,n){var o=e.loader;t&&e.loads[0].name!=t.name&&(n=j(n,'Error loading "'+t.name+'" from "'+e.loads[0].name+'" at '+(e.loads[0].address||"")+"\n")),t&&(n=j(n,'Error loading "'+t.name+'" at '+(t.address||"")+"\n"));for(var r=e.loads.concat([]),i=0,a=r.length;a>i;i++){var t=r[i];o.loaderObj.failed=o.loaderObj.failed||[],-1==k.call(o.loaderObj.failed,t)&&o.loaderObj.failed.push(t);var s=k.call(t.linkSets,e);if(console.assert(-1!=s,"link not present"),t.linkSets.splice(s,1),0==t.linkSets.length){var u=k.call(e.loader.loads,t);-1!=u&&e.loader.loads.splice(u,1)}}e.reject(n)}function f(e,t){if(e.loaderObj.trace){e.loaderObj.loads||(e.loaderObj.loads={});var n={};t.dependencies.forEach(function(e){n[e.key]=e.value}),e.loaderObj.loads[t.name]={name:t.name,deps:t.dependencies.map(function(e){return e.key}),depMap:n,address:t.address,metadata:t.metadata,source:t.source,kind:t.isDeclarative?"declarative":"dynamic"}}t.name&&(console.assert(!e.modules[t.name],"load not in module table"),e.modules[t.name]=t.module);var o=k.call(e.loads,t);-1!=o&&e.loads.splice(o,1);for(var r=0,i=t.linkSets.length;i>r;r++)o=k.call(t.linkSets[r].loads,t),-1!=o&&t.linkSets[r].loads.splice(o,1);t.linkSets.splice(0,t.linkSets.length)}function p(e,t,n){if(n[e.groupIndex]=n[e.groupIndex]||[],-1==k.call(n[e.groupIndex],e)){n[e.groupIndex].push(e);for(var o=0,r=t.length;r>o;o++)for(var i=t[o],a=0;a=0;a--){for(var s=o[a],u=0;un;n++){var a=o.importers[n];if(!a.locked){var s=k.call(a.dependencies,o);a.setters[s](r)}}return o.locked=!1,t});o.setters=i.setters,o.execute=i.execute;for(var a=0,s=e.dependencies.length;s>a;a++){var u=e.dependencies[a].value,l=n.modules[u];if(!l)for(var c=0;ci;i++){var s=r[i];if(s&&-1==k.call(t,s)&&(o=w(s,t,n)))return o=j(o,"Error evaluating "+s.name+"\n")}if(e.failed)return new Error("Module failed execution.");if(!e.evaluated)return e.evaluated=!0,o=g(e),o?e.failed=!0:Object.preventExtensions&&Object.preventExtensions(e.module),e.execute=void 0,o}}function j(e,t){return e instanceof Error?e.message=t+e.message:e=t+e,e}function x(e){if("object"!=typeof e)throw new TypeError("Options must be an object");e.normalize&&(this.normalize=e.normalize),e.locate&&(this.locate=e.locate),e.fetch&&(this.fetch=e.fetch),e.translate&&(this.translate=e.translate),e.instantiate&&(this.instantiate=e.instantiate),this._loader={loaderObj:this,loads:[],modules:{},importPromises:{},moduleRecords:{}},R(this,"global",{get:function(){return __global}})}function O(){}function E(e,t,n){var o=e._loader.importPromises;return o[t]=n.then(function(e){return o[t]=void 0,e},function(e){throw o[t]=void 0,e})}var P=__global.Promise||require("when/es6-shim/Promise");__global.console&&(console.assert=console.assert||function(){});var k=Array.prototype.indexOf||function(e){for(var t=0,n=this.length;n>t;t++)if(this[t]===e)return t;return-1},R=$__Object$defineProperty,L=0;x.prototype={constructor:x,define:function(e,t,n){if(this._loader.importPromises[e])throw new TypeError("Module is already loading.");return E(this,e,new P(a({step:"translate",loader:this._loader,moduleName:e,moduleMetadata:n&&n.metadata||{},moduleSource:t,moduleAddress:n&&n.address})))},"delete":function(e){var t=this._loader;return delete t.importPromises[e],delete t.moduleRecords[e],t.modules[e]?delete t.modules[e]:!1},get:function(e){return this._loader.modules[e]?(b(this._loader.modules[e],[],this),this._loader.modules[e].module):void 0},has:function(e){return!!this._loader.modules[e]},"import":function(e,n){var o=this;return P.resolve(o.normalize(e,n&&n.name,n&&n.address)).then(function(e){var r=o._loader;return r.modules[e]?(b(r.modules[e],[],r._loader),r.modules[e].module):r.importPromises[e]||E(o,e,t(r,e,n||{}).then(function(t){return delete r.importPromises[e],_(r,t)}))})},load:function(e){return this._loader.modules[e]?(b(this._loader.modules[e],[],this._loader),P.resolve(this._loader.modules[e].module)):this._loader.importPromises[e]||E(this,e,t(this._loader,e,{}))},module:function(t,n){var o=e();o.address=n&&n.address;var r=s(this._loader,o),a=P.resolve(t),u=this._loader,l=r.done.then(function(){return _(u,o)});return i(u,o,a),l},newModule:function(e){if("object"!=typeof e)throw new TypeError("Expected object");var t,n=new O;if(Object.getOwnPropertyNames&&null!=e)t=Object.getOwnPropertyNames(e);else{t=[];for(var o in e)t.push(o)}for(var r=0;r2)throw new TypeError("Only one wildcard in a path is permitted");if(1==s.length){if(o==i&&i.length>r.length){r=i;break}}else o.substr(0,s[0].length)==s[0]&&o.substr(o.length-s[1].length)==s[1]&&(r=i,t=o.substr(s[0].length,o.length-s[1].length-s[0].length))}var u=this.paths[r];return t&&(u=u.replace("*",t)),a&&(u=u.replace(/#/g,"%23")),n(this.baseURL,u)},enumerable:!1,writable:!0}),$__Object$defineProperty(t.prototype,"fetch",{value:function(e){var t=this;return new u(function(o,r){i(n(t.baseURL,e.address),function(e){o(e)},r)})},enumerable:!1,writable:!0}),t}(__global.LoaderPolyfill),d=new c;if("object"==typeof exports&&(module.exports=d),__global.System=d,a&&document.getElementsByTagName){var f=document.getElementsByTagName("script");f=f[f.length-1],"complete"===document.readyState?setTimeout(r):document.addEventListener&&(document.addEventListener("DOMContentLoaded",o,!1),window.addEventListener("load",o,!1)),f.getAttribute("data-init")&&window[f.getAttribute("data-init")]()}}()}("undefined"!=typeof window?window:"undefined"!=typeof global?global:self); 2 | //# sourceMappingURL=es6-module-loader@0.16.6.js.map -------------------------------------------------------------------------------- /lib/system@0.16.11.js: -------------------------------------------------------------------------------- 1 | /* 2 | * SystemJS 0.16.11 3 | * Served for jspm from https://jspm.io/system@0.16.11.js 4 | */ 5 | !function($__global,$__globalName){$__global.upgradeSystemLoader=function(){function e(e){var t=String(e).replace(/^\s+|\s+$/g,"").match(/^([^:\/?#]+:)?(\/\/(?:[^:@\/?#]*(?::[^:@\/?#]*)?@)?(([^:\/?#]*)(?::(\d*))?))?([^?#]*)(\?[^#]*)?(#[\s\S]*)?/);return t?{href:t[0]||"",protocol:t[1]||"",authority:t[2]||"",host:t[3]||"",hostname:t[4]||"",port:t[5]||"",pathname:t[6]||"",search:t[7]||"",hash:t[8]||""}:null}function t(t,a){function r(e){var t=[];return e.replace(/^(\.\.?(\/|$))+/,"").replace(/\/(\.(\/|$))+/g,"/").replace(/\/\.\.$/,"/../").replace(/\/?[^\/]*/g,function(e){"/.."===e?t.pop():t.push(e)}),t.join("").replace(/^\//,"/"===e.charAt(0)?"/":"")}return g&&(a=a.replace(/\\/g,"/")),a=e(a||""),t=e(t||""),a&&t?(a.protocol||t.protocol)+(a.protocol||a.authority?a.authority:t.authority)+r(a.protocol||a.authority||"/"===a.pathname.charAt(0)?a.pathname:a.pathname?(t.authority&&!t.pathname?"/":"")+t.pathname.slice(0,t.pathname.lastIndexOf("/")+1)+a.pathname:t.pathname)+(a.protocol||a.authority||a.pathname?a.search:a.search||t.search)+a.hash:null}function a(e){function r(e,t){t._extensions=[];for(var a=0,r=e.length;r>a;a++)e[a](t)}var n=e["import"];e["import"]=function(e,t){return n.call(this,e,t).then(function(e){return e.__useDefault?e["default"]:e})},e.set("@empty",e.newModule({})),"undefined"!=typeof require&&(e._nodeRequire=require),e.config=function(e){for(var t in e){var a=e[t];if("object"!=typeof a||a instanceof Array)this[t]=a;else{this[t]=this[t]||{};for(var r in a)this[t][r]=a[r]}}};var o;if("undefined"==typeof window&&"undefined"==typeof WorkerGlobalScope&&"undefined"!=typeof process)o="file:"+process.cwd()+"/",g&&(o=o.replace(/\\/g,"/"));else if("undefined"==typeof window)o=location.href;else if(o=document.baseURI,!o){var i=document.getElementsByTagName("base");o=i[0]&&i[0].href||window.location.href}var s,l=e.locate;e.locate=function(e){return this.baseURL!=s&&(s=t(o,this.baseURL),"/"!=s.substr(s.length-1,1)&&(s+="/"),this.baseURL=s),Promise.resolve(l.call(this,e))},e._extensions=e._extensions||[],e._extensions.push(a),e.clone=function(){var e=this,t=new LoaderPolyfill(v);return t.baseURL=e.baseURL,t.paths={"*":"*.js"},r(e._extensions,t),t}}function r(e){function t(e,t){var a=e.meta&&e.meta[t.name];if(a)for(var r in a)t.metadata[r]=t.metadata[r]||a[r]}var a=/^(\s*\/\*.*\*\/|\s*\/\/[^\n]*|\s*"[^"]+"\s*;?|\s*'[^']+'\s*;?)+/,n=/\/\*.*\*\/|\/\/[^\n]*|"[^"]+"\s*;?|'[^']+'\s*;?/g;e.meta={},e._extensions=e._extensions||[],e._extensions.push(r);var o=e.locate;e.locate=function(e){return t(this,e),o.call(this,e)};var i=e.translate;e.translate=function(e){var r=e.source.match(a);if(r)for(var o=r[0].match(n),s=0;sa;a++)-1==h.call(t,e[a])&&t.push(e[a]);return t}function o(t,a,r,n){"string"!=typeof t&&(n=r,r=a,a=t,t=null),v=!0;var o;if(o="boolean"==typeof r?{declarative:!1,deps:a,execute:n,executingRequire:r}:{declarative:!0,deps:a,declare:r},t)o.name=t,t in e.defined||(e.defined[t]=o);else if(o.declarative){if(g)throw new TypeError("Multiple anonymous System.register calls in the same module file.");g=o}}function i(e){if(!e.register){e.register=o,e.defined||(e.defined={});var t=e.onScriptLoad;e.onScriptLoad=function(e){t(e),g&&(e.metadata.entry=g),v&&(e.metadata.format=e.metadata.format||"register",e.metadata.registered=!0)}}}function s(e,t,a){if(a[e.groupIndex]=a[e.groupIndex]||[],-1==h.call(a[e.groupIndex],e)){a[e.groupIndex].push(e);for(var r=0,n=e.normalizedDeps.length;n>r;r++){var o=e.normalizedDeps[r],i=t.defined[o];if(i&&!i.evaluated){var l=e.groupIndex+(i.declarative!=e.declarative);if(void 0===i.groupIndex||i.groupIndex=0;o--){for(var i=r[o],l=0;ln;n++){var i=a.importers[n];if(!i.locked){var s=h.call(i.dependencies,a);i.setters[s](r)}}return a.locked=!1,t});if(a.setters=n.setters,a.execute=n.execute,!a.setters||!a.execute)throw new TypeError("Invalid System.register form for "+e.name);for(var o=0,i=e.normalizedDeps.length;i>o;o++){var s,l=e.normalizedDeps[o],c=t.defined[l],f=b[l];f?s=f.exports:c&&!c.declarative?s=c.module.exports&&c.module.exports.__esModule?c.module.exports:{"default":c.module.exports,__useDefault:!0}:c?(d(c,t),f=c.module,s=f.exports):s=t.get(l),f&&f.importers?(f.importers.push(a),a.dependencies.push(f)):a.dependencies.push(null),a.setters[o]&&a.setters[o](s)}}}function c(e,t){var a,r=t.defined[e];if(r)r.declarative?m(e,[],t):r.evaluated||f(r,t),a=r.module.exports;else if(a=t.get(e),!a)throw new Error("Unable to load dependency "+e+".");return(!r||r.declarative)&&a&&a.__useDefault?a["default"]:a}function f(e,t){if(!e.module){var a={},r=e.module={exports:a,id:e.name};if(!e.executingRequire)for(var n=0,o=e.normalizedDeps.length;o>n;n++){var i=e.normalizedDeps[n],s=t.defined[i];s&&f(s,t)}e.evaluated=!0;var l=e.execute.call(t.global,function(a){for(var r=0,n=e.deps.length;n>r;r++)if(e.deps[r]==a)return c(e.normalizedDeps[r],t);throw new TypeError("Module "+a+" not declared as a dependency.")},a,r);l&&(r.exports=l)}}function m(e,t,a){var r=a.defined[e];if(r&&!r.evaluated&&r.declarative){t.push(e);for(var n=0,o=r.normalizedDeps.length;o>n;n++){var i=r.normalizedDeps[n];-1==h.call(t,i)&&(a.defined[i]?m(i,t,a):a.get(i))}r.evaluated||(r.evaluated=!0,r.module.execute.call(a.global))}}"undefined"==typeof h&&(h=Array.prototype.indexOf),("undefined"==typeof __eval||"undefined"!=typeof document&&!document.addEventListener)&&(__eval=0||eval),e._extensions=e._extensions||[],e._extensions.push(n);e.__exec=a;var g,v;i(e);var b={},y=e["delete"];e["delete"]=function(e){return delete b[e],y.call(this,e)};var x=/System\.register/,_=e.fetch;e.fetch=function(e){var t=this;return i(t),t.defined[e.name]?(e.metadata.format="defined",""):(g=null,v=!1,_.call(t,e))};var w=e.translate;e.translate=function(e){return this.register=o,this.__exec=a,e.metadata.deps=e.metadata.deps||[],Promise.resolve(w.call(this,e)).then(function(t){return(e.metadata.init||e.metadata.exports)&&(e.metadata.format=e.metadata.format||"global"),("register"==e.metadata.format||!e.metadata.format&&e.source.match(x))&&(e.metadata.format="register"),t})};var S=e.instantiate;e.instantiate=function(e){var t,a=this;if(a.defined[e.name])t=a.defined[e.name],t.deps=t.deps.concat(e.metadata.deps);else if(e.metadata.entry)t=e.metadata.entry;else if(e.metadata.execute)t={declarative:!1,deps:e.metadata.deps||[],execute:e.metadata.execute,executingRequire:e.metadata.executingRequire};else if("register"==e.metadata.format){g=null,v=!1;var n=a.global.System;if(a.global.System=a,a.__exec(e),a.global.System=n,g?t=g:e.metadata.bundle=!0,!t&&p.defined[e.name]&&(t=p.defined[e.name]),!v&&!e.metadata.registered)throw new TypeError(e.name+" detected as System.register but didn't execute.")}if(!t&&"es6"!=e.metadata.format)return{deps:e.metadata.deps,execute:function(){return a.newModule({})}};if(!t)return S.call(this,e);a.defined[e.name]=t,t.deps=r(t.deps),t.name=e.name;for(var o=[],i=0,s=t.deps.length;s>i;i++)o.push(Promise.resolve(a.normalize(t.deps[i],e.name)));return Promise.all(o).then(function(r){return t.normalizedDeps=r,{deps:t.deps,execute:function(){l(e.name,a),m(e.name,[],a),a.defined[e.name]=void 0;var r=t.module.exports;return(!r||!t.declarative&&r.__esModule!==!0)&&(r={"default":r,__useDefault:!0}),a.newModule(r)}}})}}function o(e){function t(e,t,r,n){e.meta=e.meta||{};var o=e.meta[t]=e.meta[t]||{};if(o.format=o.format||"global",!e.paths[t]){var i=a(r,n);i&&(e.paths[t]=i)}}function a(e,t){if(d){var a=t?"/package.json":"";try{var r=d(e+a);return"file:"+r.substr(0,r.length-a.length)+(t?"/*.js":"")}catch(n){}}}e._extensions.push(o);var r,n,i=/(^\s*|[}\);\n]\s*)(import\s+(['"]|(\*\s+as\s+)?[^"'\(\)\n;]+\s+from\s+['"]|\{)|export\s+\*\s+from\s+["']|export\s+(\{|default|function|class|var|const|let|async\s+function))/,s=/\$traceurRuntime\s*\./,l=/babelHelpers\s*\./,u=!0,d="undefined"!=typeof process&&"undefined"!=typeof require&&require.resolve,c=e.locate;e.locate=function(e){var a=this;return u&&("traceur"==a.transpiler?(t(a,"traceur","traceur/bin/traceur.js"),a.meta.traceur.exports="traceur",t(a,"traceur-runtime","traceur/bin/traceur-runtime.js")):"babel"==a.transpiler&&(t(a,"babel","babel-core/browser.js"),t(a,"babel/external-helpers","babel-core/external-helpers.js"),t(a,"babel-runtime/*","babel-runtime",!0)),u=!1),c.call(a,e)};var f=e.translate;e.translate=function(e){var t=this;return f.call(t,e).then(function(a){if("es6"==e.metadata.format||!e.metadata.format&&a.match(i))return e.metadata.format="es6",a;if("register"==e.metadata.format){if(!t.global.$traceurRuntime&&e.source.match(s))return t["import"]("traceur-runtime").then(function(){return a});if(!t.global.babelHelpers&&e.source.match(l))return t["import"]("babel/external-helpers").then(function(){return a})}return"traceur"==t.transpiler?Promise.all([r||(r=t.normalize(t.transpiler)),n||(n=t.normalize(t.transpiler+"-runtime"))]).then(function(t){return e.name==t[0]||e.name==t[1]?"(function() { var curSystem = System; "+a+"\nSystem = curSystem; })();":a}):a})}}function i(e){function t(e,t){for(var a=e.split(".");a.length;)t=t[a.shift()];return t}function a(t){if(Object.keys)Object.keys(e.global).forEach(t);else for(var a in e.global)s.call(e.global,a)&&t(a)}function r(t){a(function(a){if(-1==h.call(o,a)){try{var r=e.global[a]}catch(n){o.push(a)}t(a,r)}})}function n(e){if(!e.has("@@global-helpers")){var a,n={};e.set("@@global-helpers",e.newModule({prepareGlobal:function(t,o){for(var i=0;ia;a++)"/"===e[a]&&t++;return t}function r(e,t,a){return a+e.substr(t)}function n(e,n,o){var i,s,l,u,d=0,c=0;if(n)for(var f in o.map){var m=o.map[f];if("object"==typeof m&&t(n,f)&&(l=a(f),!(c>=l)))for(var p in m)t(e,p)&&(u=a(p),d>=u||(i=p,d=u,s=f,c=l))}if(i)return r(e,i.length,o.map[s][i]);for(var f in o.map){var m=o.map[f];if("string"==typeof m&&t(e,f)){var u=a(f);d>=u||(i=f,d=u)}}return i?r(e,i.length,o.map[i]):e}e.map=e.map||{},e._extensions.push(u);var o=e.normalize;e.normalize=function(e,t,a){var r=this;r.map||(r.map={});var i=!1;return"/"==e.substr(e.length-1,1)&&(i=!0,e+="#"),Promise.resolve(o.call(r,e,t,a)).then(function(e){if(e=n(e,t,r),i){var a=e.split("/");a.pop();var o=a.pop();a.push(o),a.push(o),e=a.join("/")}return e})}}function d(e){"undefined"==typeof h&&(h=Array.prototype.indexOf),e._extensions.push(d);var t=e.normalize;e.normalize=function(e,a,r){var n,o=this;return a&&-1!=(n=a.indexOf("!"))&&(a=a.substr(0,n)),Promise.resolve(t.call(o,e,a,r)).then(function(e){var t=e.lastIndexOf("!");if(-1!=t){var n=e.substr(0,t),i=e.substr(t+1)||n.substr(n.lastIndexOf(".")+1);return new Promise(function(e){e(o.normalize(i,a,r))}).then(function(e){return i=e,o.normalize(n,a,r)}).then(function(e){return e+"!"+i})}return e})};var a=e.locate;e.locate=function(e){var t=this,r=e.name;if(this.defined&&this.defined[r])return a.call(this,e);var n=r.lastIndexOf("!");if(-1!=n){var o=r.substr(n+1);e.name=r.substr(0,n);var i=t.pluginLoader||t;return i["import"](o).then(function(){var a=i.get(o);return a=a["default"]||a,a.build===!1&&t.pluginLoader&&(e.metadata.build=!1),e.metadata.plugin=a,e.metadata.pluginName=o,e.metadata.pluginArgument=e.name,a.locate?a.locate.call(t,e):Promise.resolve(t.locate(e)).then(function(e){return e.replace(/\.js$/,"")})})}return a.call(this,e)};var r=e.fetch;e.fetch=function(e){var t=this;return e.metadata.build===!1&&t.pluginLoader?"":e.metadata.plugin&&e.metadata.plugin.fetch&&!e.metadata.pluginFetchCalled?(e.metadata.pluginFetchCalled=!0,e.metadata.plugin.fetch.call(t,e,r)):r.call(t,e)};var n=e.translate;e.translate=function(e){var t=this;return e.metadata.plugin&&e.metadata.plugin.translate?Promise.resolve(e.metadata.plugin.translate.call(t,e)).then(function(a){return"string"==typeof a&&(e.source=a),n.call(t,e)}):n.call(t,e)};var o=e.instantiate;e.instantiate=function(e){var t=this;return e.metadata.plugin&&e.metadata.plugin.instantiate?Promise.resolve(e.metadata.plugin.instantiate.call(t,e)).then(function(a){return e.metadata.format="defined",e.metadata.execute=function(){return a},o.call(t,e)}):e.metadata.plugin&&e.metadata.plugin.build===!1?(e.metadata.format="defined",e.metadata.deps.push(e.metadata.pluginName),e.metadata.execute=function(){return t.newModule({})},o.call(t,e)):o.call(t,e)}}function c(e){function t(e,t){return Promise.resolve(e.normalize(t)).then(function(r){return-1==h.call(a,r)&&(a.push(r),e.bundles[r]=e.bundles[r]||e.bundles[t],e.meta=e.meta||{},e.meta[r]=e.meta[r]||{},e.meta[r].bundle=!0),e.load(r)}).then(function(){return""})}"undefined"==typeof h&&(h=Array.prototype.indexOf),e._extensions.push(c),e.bundles=e.bundles||{};var a=[],r=e.fetch;e.fetch=function(e){var n=this;if(n.trace)return r.call(this,e);n.bundles||(n.bundles={});for(var o=0;oi?1:-1}if(!e.pre&&!a.pre)return 0;if(!e.pre)return 1;if(!a.pre)return-1;for(var r=0,s=Math.min(e.pre.length,a.pre.length);s>r;r++)if(e.pre[r]!=a.pre[r]){var d=e.pre[r].match(l),c=a.pre[r].match(l);return d&&!c?-1:c&&!d?1:d&&c?t(e.pre[r])>t(a.pre[r])?1:-1:e.pre[r]>a.pre[r]?1:-1}return e.pre.length==a.pre.length?0:e.pre.length>a.pre.length?1:-1}function n(e,t){var a=e.version;return a.tag?a.tag==t.tag:1==r(a,t)?!1:isNaN(t.minor)||isNaN(t.patch)?!1:t.pre?a.major!=t.major||a.minor!=t.minor||a.patch!=t.patch?!1:e.semver||e.fuzzy||a.pre.join(".")==t.pre.join("."):e.semver?0==a.major&&isNaN(a.minor)?t.major<1:a.major>=1?a.major==t.major:a.minor>=1?a.minor==t.minor:(a.patch||0)==t.patch:e.fuzzy?t.major==a.major&&t.minor<(a.minor||0)+1:!a.pre&&a.major==t.major&&a.minor==t.minor&&a.patch==t.patch}function o(e){var t={};((t.semver="^"==e.substr(0,1))||(t.fuzzy="~"==e.substr(0,1)))&&(e=e.substr(1));var r=t.version=a(e);return r.tag?t:(t.fuzzy||t.semver||!isNaN(r.minor)&&!isNaN(r.patch)||(t.fuzzy=!0),t.fuzzy&&isNaN(r.minor)&&(t.semver=!0,t.fuzzy=!1),t.semver&&!isNaN(r.minor)&&isNaN(r.patch)&&(t.semver=!1,t.fuzzy=!0),t)}function i(e,t){return r(a(e),a(t))}"undefined"==typeof h&&(h=Array.prototype.indexOf),e._extensions.push(f);var s=/^(\d+)(?:\.(\d+)(?:\.(\d+)(?:-([\da-z-]+(?:\.[\da-z-]+)*)(?:\+([\da-z-]+(?:\.[\da-z-]+)*))?)?)?)?$/i,l=/^\d+$/,u=["major","minor","patch"];e.versions=e.versions||{};var d=e.normalize;e.normalize=function(e,t,r){this.versions||(this.versions={});var s,l,u=this.versions,c=-1!=e.indexOf("!")?0:e.lastIndexOf("@");if(c>0){var f=e.substr(c+1,e.length-c-1).split("/");s=f[0],l=f.length,e=e.substr(0,c)+e.substr(c+s.length+1,e.length-c-s.length-1)}return Promise.resolve(d.call(this,e,t,r)).then(function(e){var t=-1!=e.indexOf("!")?0:e.indexOf("@");if(s&&(-1==t||0==t)){var r=e.split("/");r[r.length-l]+="@"+s,e=r.join("/"),t=e.indexOf("@")}var d,c;if(-1==t||0==t){for(var f in u)if(c=u[f],e.substr(0,f.length)==f&&(d=e.substr(f.length,1),!d||"/"==d))return f+"@"+("string"==typeof c?c:c[c.length-1])+e.substr(f.length);return e}var m=e.substr(0,t),p=e.substr(t+1).split("/")[0],h=p.length,g=o(e.substr(t+1).split("/")[0]);c=u[e.substr(0,t)]||[],"string"==typeof c&&(c=[c]);for(var v=c.length-1;v>=0;v--)if(n(g,a(c[v])))return m+"@"+c[v]+e.substr(t+h+1);var b;return g.semver?b=0!=g.version.major||isNaN(g.version.minor)?g.version.major:"0."+g.version.minor:g.fuzzy?b=g.version.major+"."+g.version.minor:(b=p,c.push(p),c.sort(i),u[m]=1==c.length?c[0]:c),m+"@"+b+e.substr(t+h+1)})}}function m(e){e.depCache=e.depCache||{},e._extensions.push(m);var t=e.locate;e.locate=function(e){var a=this;a.depCache||(a.depCache={});var r=a.depCache[e.name];if(r)for(var n=0;nt;t++)if(this[t]===e)return t;return-1},g="undefined"!=typeof process&&!!process.platform.match(/^win/);!function(){var e=$__global.System;p=$__global.System=new LoaderPolyfill(e),p.baseURL=e.baseURL,p.paths={"*":"*.js"},p.originalSystem=e}(),p.noConflict=function(){$__global.SystemJS=p,$__global.System=p.originalSystem};var v=$__global.System.originalSystem;a(p),r(p),n(p),o(p),i(p),s(p),l(p),u(p),d(p),c(p),f(p),m(p)};var $__curScript,__eval;!function(){var doEval;if(__eval=function(e,t,a){e+="\n//# sourceURL="+t+(a?"\n//# sourceMappingURL="+a:"");try{doEval(e)}catch(r){var n="Error evaluating "+t+"\n";throw r instanceof Error?r.message=n+r.message:r=n+r,r}},"undefined"!=typeof document){var head,scripts=document.getElementsByTagName("script");if($__curScript=scripts[scripts.length-1],doEval=function(e){head||(head=document.head||document.body||document.documentElement);var t=document.createElement("script");t.text=e;var a,r=window.onerror;if(window.onerror=function(e){a=e},head.appendChild(t),head.removeChild(t),window.onerror=r,a)throw a},$__global.System&&$__global.LoaderPolyfill)$__global.upgradeSystemLoader();else{var curPath=$__curScript.src,basePath=curPath.substr(0,curPath.lastIndexOf("/")+1);document.write('')}}else if("undefined"!=typeof importScripts)if(doEval=function(source){try{eval(source)}catch(e){throw e}},$__global.System&&$__global.LoaderPolyfill)$__global.upgradeSystemLoader();else{var basePath="";try{throw new Error("Get worker base path via error stack")}catch(e){e.stack.replace(/(?:at|@).*(http.+):[\d]+:[\d]+/,function(e,t){basePath=t.replace(/\/[^\/]*$/,"/")})}importScripts(basePath+"es6-module-loader@0.16.6.js"),$__global.upgradeSystemLoader()}else{var es6ModuleLoader=require("es6-module-loader");$__global.System=es6ModuleLoader.System,$__global.Loader=es6ModuleLoader.Loader,$__global.upgradeSystemLoader(),module.exports=$__global.System;var vm=require("vm");doEval=function(e){vm.runInThisContext(e)}}}()}("undefined"!=typeof window?window:"undefined"!=typeof global?global:self,"undefined"!=typeof window?"window":"undefined"!=typeof global?"global":"self"),function(e){var t=e.upgradeSystemLoader;e.upgradeSystemLoader=function(){t&&t(),System.config({paths:{"*":"https://registry.jspm.io/*.js","~/*":"*.js","npm:*":"https://npm.jspm.io/*.js","github:*":"https://github.jspm.io/*.js"},map:{traceur:"github:jmcriffey/bower-traceur@0.0.87","traceur-runtime":"github:jmcriffey/bower-traceur-runtime@0.0.87",babel:"npm:babel-core@5"}}),e.upgradeSystemLoader=void 0},t||e.upgradeSystemLoader()}("undefined"!=typeof window?window:global); 6 | //# sourceMappingURL=system@0.16.11.js.map -------------------------------------------------------------------------------- /lib/traceur-runtime.js: -------------------------------------------------------------------------------- 1 | /* */ 2 | "format global";"exports $traceurRuntime";!function(t){"use strict";function e(t,e,r){for(var n=[e],i=0;i0;)i.unshift("..");0===i.length&&i.push(".")}return e+i.join("/")+r}function n(e){var n=e[a.PATH]||"";return n=r(n),e[a.PATH]=n,t(e[a.SCHEME],e[a.USER_INFO],e[a.DOMAIN],e[a.PORT],e[a.PATH],e[a.QUERY_DATA],e[a.FRAGMENT])}function i(t){var r=e(t);return n(r)}function o(t,r){var i=e(r),o=e(t);if(i[a.SCHEME])return n(i);i[a.SCHEME]=o[a.SCHEME];for(var u=a.SCHEME;u<=a.PORT;u++)i[u]||(i[u]=o[u]);if("/"==i[a.PATH][0])return n(i);var c=o[a.PATH],s=c.lastIndexOf("/");return c=c.slice(0,s+1)+i[a.PATH],i[a.PATH]=c,n(i)}function u(t){if(!t)return!1;if("/"===t[0])return!0;var r=e(t);return r[a.SCHEME]?!0:!1}var c=new RegExp("^"+"(?:"+"([^:/?#.]+)"+":)?"+"(?://"+"(?:([^/?#]*)@)?"+"([\\w\\d\\-\\u0100-\\uffff.%]*)"+"(?::([0-9]+))?"+")?"+"([^?#]+)?"+"(?:\\?([^#]*))?"+"(?:#(.*))?"+"$"),a={SCHEME:1,USER_INFO:2,DOMAIN:3,PORT:4,PATH:5,QUERY_DATA:6,FRAGMENT:7};$traceurRuntime.canonicalizeUrl=i,$traceurRuntime.isAbsolute=u,$traceurRuntime.removeDotSegments=r,$traceurRuntime.resolveUrl=o}(),function(t){"use strict";function e(t,e){this.url=t,this.value_=e}function r(t,e){this.message=this.constructor.name+": "+this.stripCause(e)+" in "+t,this.stack=e instanceof r||!e.stack?"":this.stripStack(e.stack)}function n(t,e){var r=[],n=e-3;0>n&&(n=0);for(var i=n;e>i;i++)r.push(t[i]);return r}function i(t,e){var r=e+1;r>t.length-1&&(r=t.length-1);for(var n=[],i=e;r>=i;i++)n.push(t[i]);return n}function o(t){for(var e="",r=0;t-1>r;r++)e+="-";return e}function u(t,r){e.call(this,t,null),this.func=r}function c(t){if(t){var e=v.normalize(t);return p[e]}}function a(t){var e=arguments[1],r=Object.create(null);return Object.getOwnPropertyNames(t).forEach(function(n){var i,o;if(e===y){var u=Object.getOwnPropertyDescriptor(t,n);u.get&&(i=u.get)}i||(o=t[n],i=function(){return o}),Object.defineProperty(r,n,{get:i,enumerable:!0})}),Object.preventExtensions(r),r}var s,l=$traceurRuntime,f=l.canonicalizeUrl,h=l.resolveUrl,m=l.isAbsolute,p=Object.create(null);s=t.location&&t.location.href?h(t.location.href,"./"):"",r.prototype=Object.create(Error.prototype),r.prototype.constructor=r,r.prototype.stripError=function(t){return t.replace(/.*Error:/,this.constructor.name+":")},r.prototype.stripCause=function(t){return t?t.message?this.stripError(t.message):t+"":""},r.prototype.loadedBy=function(t){this.stack+="\n loaded by "+t},r.prototype.stripStack=function(t){var e=[];return t.split("\n").some(function(t){return/UncoatedModuleInstantiator/.test(t)?!0:void e.push(t)}),e[0]=this.stripError(e[0]),e.join("\n")},u.prototype=Object.create(e.prototype),u.prototype.getUncoatedModule=function(){if(this.value_)return this.value_;try{var e;return void 0!==typeof $traceurRuntime&&$traceurRuntime.require&&(e=$traceurRuntime.require.bind(null,this.url)),this.value_=this.func.call(t,e)}catch(u){if(u instanceof r)throw u.loadedBy(this.url),u;if(u.stack){var c=this.func.toString().split("\n"),a=[];u.stack.split("\n").some(function(t){if(t.indexOf("UncoatedModuleInstantiator.getUncoatedModule")>0)return!0;var e=/(at\s[^\s]*\s).*>:(\d*):(\d*)\)/.exec(t);if(e){var r=parseInt(e[2],10);a=a.concat(n(c,r)),a.push(o(e[3])+"^"),a=a.concat(i(c,r)),a.push("= = = = = = = = =")}else a.push(t)}),u.stack=a.join("\n")}throw new r(this.url,u)}};var b=Object.create(null),y={},v={normalize:function(t,e){if("string"!=typeof t)throw new TypeError("module name must be a string, not "+typeof t);if(m(t))return f(t);if(/[^\.]\/\.\.\//.test(t))throw new Error("module name embeds /../: "+t);return"."===t[0]&&e?h(e,t):f(t)},get:function(t){var e=c(t);if(!e)return void 0;var r=b[e.url];return r?r:(r=a(e.getUncoatedModule(),y),b[e.url]=r)},set:function(t,e){t=String(t),p[t]=new u(t,function(){return e}),b[t]=e},get baseURL(){return s},set baseURL(t){s=String(t)},registerModule:function(t,e,r){var n=v.normalize(t);if(p[n])throw new Error("duplicate module named "+n);p[n]=new u(n,r)},bundleStore:Object.create(null),register:function(t,e,r){e&&(e.length||r.length)?this.bundleStore[t]={deps:e,execute:function(){var t=arguments,n={};e.forEach(function(e,r){return n[e]=t[r]});var i=r.call(this,n);return i.execute.call(this),i.exports}}:this.registerModule(t,e,r)},getAnonymousModule:function(e){return new a(e.call(t),y)},getForTesting:function(t){var e=this;return this.testingPrefix_||Object.keys(b).some(function(t){var r=/(traceur@[^\/]*\/)/.exec(t);return r?(e.testingPrefix_=r[1],!0):void 0}),this.get(this.testingPrefix_+t)}},g=new a({ModuleStore:v});v.set("@traceur/src/runtime/ModuleStore",g),v.set("@traceur/src/runtime/ModuleStore.js",g);var d=$traceurRuntime.setupGlobals;$traceurRuntime.setupGlobals=function(t){d(t)},$traceurRuntime.ModuleStore=v,t.System={register:v.register.bind(v),registerModule:v.registerModule.bind(v),get:v.get,set:v.set,normalize:v.normalize},$traceurRuntime.getModuleImpl=function(t){var e=c(t);return e&&e.getUncoatedModule()}}("undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:this),System.registerModule("traceur-runtime@0.0.87/src/runtime/async.js",[],function(){"use strict";function t(){}function e(){}function r(t){return t.prototype=s(e.prototype),t.__proto__=e,t}function n(t,e){for(var r=[],n=2;n3?("function"==typeof n&&(t.__proto__=n),t.prototype=s(u(n),i(e))):t.prototype=e,f(t,"prototype",{configurable:!1,writable:!1}),l(t,i(r))}function u(t){if("function"==typeof t){var e=t.prototype;if(c(e)===e||null===e)return t.prototype;throw new a("super prototype must be an Object or null")}if(null===t)return null;throw new a("Super expression must either be null or a function, not "+typeof t+".")}var c=Object,a=TypeError,s=c.create,l=$traceurRuntime.defineProperties,f=$traceurRuntime.defineProperty,h=$traceurRuntime.getOwnPropertyDescriptor,m=($traceurRuntime.getOwnPropertyNames,Object.getPrototypeOf),p=Object,b=p.getOwnPropertyNames,y=p.getOwnPropertySymbols;return $traceurRuntime.createClass=o,$traceurRuntime.superConstructor=e,$traceurRuntime.superGet=r,$traceurRuntime.superSet=n,{}}),System.registerModule("traceur-runtime@0.0.87/src/runtime/destructuring.js",[],function(){"use strict";function t(t){for(var e,r=[],n=0;!(e=t.next()).done;)r[n++]=e.value;return r}return $traceurRuntime.iteratorToArray=t,{}}),System.registerModule("traceur-runtime@0.0.87/src/runtime/generators.js",[],function(){"use strict";function t(t){return{configurable:!0,enumerable:!1,value:t,writable:!0}}function e(t){return new Error("Traceur compiler bug: invalid state in state machine: "+t)}function r(){this.state=0,this.GState=v,this.storedException=void 0,this.finallyFallThrough=void 0,this.sent_=void 0,this.returnValue=void 0,this.oldReturnValue=void 0,this.tryStack_=[]}function n(t,e,r,n){switch(t.GState){case g:throw new Error('"'+r+'" on executing generator');case j:if("next"==r)return{value:void 0,done:!0};if(n===S)return{value:t.returnValue,done:!0};throw n;case v:if("throw"===r){if(t.GState=j,n===S)return{value:t.returnValue,done:!0};throw n}if(void 0!==n)throw y("Sent value to newborn generator");case d:t.GState=g,t.action=r,t.sent=n;var i;try{i=e(t)}catch(o){if(o!==S)throw o;i=t}var u=i===t;return u&&(i=t.returnValue),t.GState=u?j:d,{value:i,done:u}}}function i(){}function o(){}function u(t,e,n){var i=l(t,n),o=new r,u=b(e.prototype);return u[R]=o,u[_]=i,u}function c(t){return t.prototype=b(o.prototype),t.__proto__=o,t}function a(){r.call(this),this.err=void 0;var t=this;t.result=new Promise(function(e,r){t.resolve=e,t.reject=r})}function s(t,e){var r=l(t,e),n=new a;return n.createCallback=function(t){return function(e){n.state=t,n.value=e,r(n)}},n.errback=function(t){f(n,t),r(n)},r(n),n.result}function l(t,e){return function(r){for(;!0;)try{return t.call(e,r)}catch(n){f(r,n)}}}function f(t,e){t.storedException=e;var r=t.tryStack_[t.tryStack_.length-1];return r?(t.state=void 0!==r["catch"]?r["catch"]:r["finally"],void(void 0!==r.finallyFallThrough&&(t.finallyFallThrough=r.finallyFallThrough))):void t.handleException(e)}if("object"!=typeof $traceurRuntime)throw new Error("traceur runtime not found.");var h=$traceurRuntime.createPrivateName,m=$traceurRuntime.defineProperties,p=$traceurRuntime.defineProperty,b=Object.create,y=TypeError,v=0,g=1,d=2,j=3,w=-2,O=-3,S={};r.prototype={pushTry:function(t,e){if(null!==e){for(var r=null,n=this.tryStack_.length-1;n>=0;n--)if(void 0!==this.tryStack_[n]["catch"]){r=this.tryStack_[n]["catch"];break}null===r&&(r=O),this.tryStack_.push({"finally":e,finallyFallThrough:r})}null!==t&&this.tryStack_.push({"catch":t})},popTry:function(){this.tryStack_.pop()},maybeUncatchable:function(){if(this.storedException===S)throw S},get sent(){return this.maybeThrow(),this.sent_},set sent(t){this.sent_=t},get sentIgnoreThrow(){return this.sent_},maybeThrow:function(){if("throw"===this.action)throw this.action="next",this.sent_},end:function(){switch(this.state){case w:return this;case O:throw this.storedException;default:throw e(this.state)}},handleException:function(t){throw this.GState=j,this.state=w,t},wrapYieldStar:function(t){var e=this;return{next:function(e){return t.next(e)},"throw":function(r){var n;if(r===S){if(t["return"]){if(n=t["return"](e.returnValue),!n.done)return e.returnValue=e.oldReturnValue,n;e.returnValue=n.value}throw r}if(t["throw"])return t["throw"](r);throw t["return"]&&t["return"](),y("Inner iterator does not have a throw method")}}}};var R=h(),_=h();return i.prototype=o,p(o,"constructor",t(i)),o.prototype={constructor:o,next:function(t){return n(this[R],this[_],"next",t)},"throw":function(t){return n(this[R],this[_],"throw",t)},"return":function(t){return this[R].oldReturnValue=this[R].returnValue,this[R].returnValue=t,n(this[R],this[_],"throw",S)}},m(o.prototype,{constructor:{enumerable:!1},next:{enumerable:!1},"throw":{enumerable:!1},"return":{enumerable:!1}}),Object.defineProperty(o.prototype,Symbol.iterator,t(function(){return this})),a.prototype=b(r.prototype),a.prototype.end=function(){switch(this.state){case w:this.resolve(this.returnValue);break;case O:this.reject(this.storedException);break;default:this.reject(e(this.state))}},a.prototype.handleException=function(){this.state=O},$traceurRuntime.asyncWrap=s,$traceurRuntime.initGeneratorFunction=c,$traceurRuntime.createGeneratorInstance=u,{}}),System.registerModule("traceur-runtime@0.0.87/src/runtime/relativeRequire.js",[],function(){"use strict";function t(t,r){function n(t){return"/"===t.slice(-1)}function i(t){return"/"===t[0]}function o(t){return"."===t[0]}return e=e||"undefined"!=typeof require&&require("path"),n(r)||i(r)?void 0:require(o(r)?e.resolve(e.dirname(t),r):r)}var e;return $traceurRuntime.require=t,{}}),System.registerModule("traceur-runtime@0.0.87/src/runtime/spread.js",[],function(){"use strict";function t(){for(var t,e=[],r=0,n=0;n>>0}function e(t){return t&&("object"==typeof t||"function"==typeof t)}function r(t){return"function"==typeof t}function n(t){return"number"==typeof t}function i(t){return t=+t,j(t)?0:0!==t&&d(t)?t>0?g(t):v(t):t}function o(t){var e=i(t);return 0>e?0:O(e,R)}function u(t){return e(t)?t[Symbol.iterator]:void 0}function c(t){return r(t)}function a(t,e){return{value:t,done:e}}function s(t,e,r){e in t||Object.defineProperty(t,e,r)}function l(t,e,r){s(t,e,{value:r,configurable:!0,enumerable:!1,writable:!0})}function f(t,e,r){s(t,e,{value:r,configurable:!1,enumerable:!1,writable:!1})}function h(t,e){for(var r=0;rt;t+=2){var e=h[t],r=h[t+1];e(r),h[t]=void 0,h[t+1]=void 0}c=0}var u,c=0,a=t,s="undefined"!=typeof window?window:{},l=s.MutationObserver||s.WebKitMutationObserver,f="undefined"!=typeof Uint8ClampedArray&&"undefined"!=typeof importScripts&&"undefined"!=typeof MessageChannel,h=new Array(1e3);return u="undefined"!=typeof process&&"[object process]"==={}.toString.call(process)?e():l?r():f?n():i(),{get default(){return a}}}),System.registerModule("traceur-runtime@0.0.87/src/runtime/polyfills/Promise.js",[],function(){"use strict";function t(t){return t&&"object"==typeof t&&void 0!==t.status_}function e(t){return t}function r(t){throw t}function n(t){var n=arguments[1]!==void 0?arguments[1]:e,o=arguments[2]!==void 0?arguments[2]:r,u=i(t.constructor);switch(t.status_){case void 0:throw TypeError;case 0:t.onResolve_.push(n,u),t.onReject_.push(o,u);break;case+1:l(t.value_,[n,u]);break;case-1:l(t.value_,[o,u])}return u.promise}function i(t){if(this===d){var e=u(new d(v));return{promise:e,resolve:function(t){c(e,t)},reject:function(t){a(e,t)}}}var r={};return r.promise=new t(function(t,e){r.resolve=t,r.reject=e}),r}function o(t,e,r,n,i){return t.status_=e,t.value_=r,t.onResolve_=n,t.onReject_=i,t}function u(t){return o(t,0,void 0,[],[])}function c(t,e){s(t,+1,e,t.onResolve_)}function a(t,e){s(t,-1,e,t.onReject_)}function s(t,e,r,n){0===t.status_&&(l(r,n),o(t,e,r))}function l(t,e){b(function(){for(var r=0;r=s)return t[o(c)]=void 0,n(void 0,!0);var l,f=e.charCodeAt(r);if(55296>f||f>56319||r+1===s)l=String.fromCharCode(f);else{var h=e.charCodeAt(r+1);l=56320>h||h>57343?String.fromCharCode(f):String.fromCharCode(f)+String.fromCharCode(h)}return t[o(a)]=r+l.length,n(l,!1)},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(e,Symbol.iterator,{value:function(){return this},configurable:!0,enumerable:!0,writable:!0}),e),{}),{get createStringIterator(){return t}}}),System.registerModule("traceur-runtime@0.0.87/src/runtime/polyfills/String.js",[],function(){"use strict";function t(t){var e=String(this);if(null==this||"[object RegExp]"==p.call(t))throw TypeError();var r=e.length,n=String(t),i=(n.length,arguments.length>1?arguments[1]:void 0),o=i?Number(i):0;isNaN(o)&&(o=0);var u=Math.min(Math.max(o,0),r);return b.call(e,n,o)==u}function e(t){var e=String(this);if(null==this||"[object RegExp]"==p.call(t))throw TypeError();var r=e.length,n=String(t),i=n.length,o=r;if(arguments.length>1){var u=arguments[1];void 0!==u&&(o=u?Number(u):0,isNaN(o)&&(o=0))}var c=Math.min(Math.max(o,0),r),a=c-i;return 0>a?!1:y.call(e,n,a)==a}function r(t){if(null==this)throw TypeError();var e=String(this);if(t&&"[object RegExp]"==p.call(t))throw TypeError();var r=e.length,n=String(t),i=n.length,o=arguments.length>1?arguments[1]:void 0,u=o?Number(o):0;u!=u&&(u=0);var c=Math.min(Math.max(u,0),r);return i+c>r?!1:b.call(e,n,u)!=-1}function n(t){if(null==this)throw TypeError();var e=String(this),r=t?Number(t):0;if(isNaN(r)&&(r=0),0>r||r==1/0)throw RangeError();if(0==r)return"";for(var n="";r--;)n+=e;return n}function i(t){if(null==this)throw TypeError();var e=String(this),r=e.length,n=t?Number(t):0;if(isNaN(n)&&(n=0),0>n||n>=r)return void 0;var i,o=e.charCodeAt(n);return o>=55296&&56319>=o&&r>n+1&&(i=e.charCodeAt(n+1),i>=56320&&57343>=i)?1024*(o-55296)+i-56320+65536:o}function o(t){var e=t.raw,r=e.length>>>0;if(0===r)return"";for(var n="",i=0;!0;){if(n+=e[i],i+1===r)return n;n+=arguments[++i]}}function u(){var t,e,r=[],n=Math.floor,i=-1,o=arguments.length;if(!o)return"";for(;++iu||u>1114111||n(u)!=u)throw RangeError("Invalid code point: "+u);65535>=u?r.push(u):(u-=65536,t=(u>>10)+55296,e=u%1024+56320,r.push(t,e))}return String.fromCharCode.apply(null,r)}function c(){var t=$traceurRuntime.checkObjectCoercible(this),e=String(t);return s(e)}function a(a){var s=a.String;f(s.prototype,["codePointAt",i,"endsWith",e,"includes",r,"repeat",n,"startsWith",t]),f(s,["fromCodePoint",u,"raw",o]),h(s.prototype,c,Symbol)}var s=System.get("traceur-runtime@0.0.87/src/runtime/polyfills/StringIterator.js").createStringIterator,l=System.get("traceur-runtime@0.0.87/src/runtime/polyfills/utils.js"),f=l.maybeAddFunctions,h=l.maybeAddIterator,m=l.registerPolyfill,p=Object.prototype.toString,b=String.prototype.indexOf,y=String.prototype.lastIndexOf;return m(a),{get startsWith(){return t},get endsWith(){return e},get includes(){return r},get repeat(){return n},get codePointAt(){return i},get raw(){return o},get fromCodePoint(){return u},get stringPrototypeIterator(){return c},get polyfillString(){return a}}}),System.get("traceur-runtime@0.0.87/src/runtime/polyfills/String.js"+""),System.registerModule("traceur-runtime@0.0.87/src/runtime/polyfills/ArrayIterator.js",[],function(){"use strict";function t(t,e){var r=u(t),n=new h;return n.iteratorObject_=r,n.arrayIteratorNextIndex_=0,n.arrayIterationKind_=e,n}function e(){return t(this,f)}function r(){return t(this,s)}function n(){return t(this,l)}var i,o=System.get("traceur-runtime@0.0.87/src/runtime/polyfills/utils.js"),u=o.toObject,c=o.toUint32,a=o.createIteratorResultObject,s=1,l=2,f=3,h=function(){};return $traceurRuntime.createClass(h,(i={},Object.defineProperty(i,"next",{value:function(){var t=u(this),e=t.iteratorObject_;if(!e)throw new TypeError("Object is not an ArrayIterator");var r=t.arrayIteratorNextIndex_,n=t.arrayIterationKind_,i=c(e.length);return r>=i?(t.arrayIteratorNextIndex_=1/0,a(void 0,!0)):(t.arrayIteratorNextIndex_=r+1,n==l?a(e[r],!1):n==f?a([r,e[r]],!1):a(r,!1))},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(i,Symbol.iterator,{value:function(){return this},configurable:!0,enumerable:!0,writable:!0}),i),{}),{get entries(){return e},get keys(){return r},get values(){return n}}}),System.registerModule("traceur-runtime@0.0.87/src/runtime/polyfills/Array.js",[],function(){"use strict";function t(t){var e,r,n=arguments[1],i=arguments[2],o=this,u=j(t),c=void 0!==n,a=0;if(c&&!m(n))throw TypeError();if(h(u)){e=p(o)?new o:[];var s=!0,l=!1,f=void 0;try{for(var b=void 0,y=u[$traceurRuntime.toProperty(Symbol.iterator)]();!(s=(b=y.next()).done);s=!0){var v=b.value;e[a]=c?n.call(i,v,a):v,a++}}catch(g){l=!0,f=g}finally{try{s||null==y["return"]||y["return"]()}finally{if(l)throw f}}return e.length=a,e}for(r=d(u.length),e=p(o)?new o(r):new Array(r);r>a;a++)e[a]=c?"undefined"==typeof i?n(u[a],a):n.call(i,u[a],a):u[a];return e.length=r,e}function e(){for(var t=[],e=0;eo;o++)i[o]=t[o];return i.length=n,i}function r(t){var e=arguments[1]!==void 0?arguments[1]:0,r=arguments[2],n=j(this),i=d(n.length),o=g(e),u=void 0!==r?g(r):i;for(o=0>o?Math.max(i+o,0):Math.min(o,i),u=0>u?Math.max(i+u,0):Math.min(u,i);u>o;)n[o]=t,o++;return n}function n(t){var e=arguments[1];return o(this,t,e)}function i(t){var e=arguments[1];return o(this,t,e,!0)}function o(t,e){var r=arguments[2],n=arguments[3]!==void 0?arguments[3]:!1,i=j(t),o=d(i.length);if(!m(e))throw TypeError();for(var u=0;o>u;u++){var c=i[u];if(e.call(r,c,u,i))return n?u:c}return n?-1:void 0}function u(o){var u=o,c=u.Array,f=u.Object,h=u.Symbol,m=l;h&&h.iterator&&c.prototype[h.iterator]&&(m=c.prototype[h.iterator]),b(c.prototype,["entries",a,"keys",s,"values",m,"fill",r,"find",n,"findIndex",i]),b(c,["from",t,"of",e]),y(c.prototype,m,h),y(f.getPrototypeOf([].values()),function(){return this},h)}var c=System.get("traceur-runtime@0.0.87/src/runtime/polyfills/ArrayIterator.js"),a=c.entries,s=c.keys,l=c.values,f=System.get("traceur-runtime@0.0.87/src/runtime/polyfills/utils.js"),h=f.checkIterable,m=f.isCallable,p=f.isConstructor,b=f.maybeAddFunctions,y=f.maybeAddIterator,v=f.registerPolyfill,g=f.toInteger,d=f.toLength,j=f.toObject;return v(u),{get from(){return t},get of(){return e},get fill(){return r},get find(){return n},get findIndex(){return i},get polyfillArray(){return u}}}),System.get("traceur-runtime@0.0.87/src/runtime/polyfills/Array.js"+""),System.registerModule("traceur-runtime@0.0.87/src/runtime/polyfills/Object.js",[],function(){"use strict";function t(t,e){return t===e?0!==t||1/t===1/e:t!==t&&e!==e}function e(t){for(var e=1;ei;i++){var u=n[i];f(u)||(t[u]=r[u])}}return t}function r(t,e){var r,n,i=l(e),o=i.length;for(r=0;o>r;r++){var u=i[r];f(u)||(n=s(e,i[r]),a(t,i[r],n))}return t}function n(n){var i=n.Object;o(i,["assign",e,"is",t,"mixin",r])}var i=System.get("traceur-runtime@0.0.87/src/runtime/polyfills/utils.js"),o=i.maybeAddFunctions,u=i.registerPolyfill,c=$traceurRuntime,a=c.defineProperty,s=c.getOwnPropertyDescriptor,l=c.getOwnPropertyNames,f=c.isPrivateName,h=c.keys;return u(n),{get is(){return t},get assign(){return e},get mixin(){return r},get polyfillObject(){return n}}}),System.get("traceur-runtime@0.0.87/src/runtime/polyfills/Object.js"+""),System.registerModule("traceur-runtime@0.0.87/src/runtime/polyfills/Number.js",[],function(){"use strict";function t(t){return u(t)&&h(t)}function e(e){return t(e)&&l(e)===e}function r(t){return u(t)&&m(t)}function n(e){if(t(e)){var r=l(e);if(r===e)return f(r)<=p}return!1}function i(i){var o=i.Number;c(o,["MAX_SAFE_INTEGER",p,"MIN_SAFE_INTEGER",b,"EPSILON",y]),a(o,["isFinite",t,"isInteger",e,"isNaN",r,"isSafeInteger",n])}var o=System.get("traceur-runtime@0.0.87/src/runtime/polyfills/utils.js"),u=o.isNumber,c=o.maybeAddConsts,a=o.maybeAddFunctions,s=o.registerPolyfill,l=o.toInteger,f=Math.abs,h=isFinite,m=isNaN,p=Math.pow(2,53)-1,b=-Math.pow(2,53)+1,y=Math.pow(2,-52);return s(i),{get MAX_SAFE_INTEGER(){return p},get MIN_SAFE_INTEGER(){return b},get EPSILON(){return y},get isFinite(){return t},get isInteger(){return e},get isNaN(){return r},get isSafeInteger(){return n},get polyfillNumber(){return i}}}),System.get("traceur-runtime@0.0.87/src/runtime/polyfills/Number.js"+""),System.registerModule("traceur-runtime@0.0.87/src/runtime/polyfills/fround.js",[],function(){"use strict";function t(t,e,r){function n(t){var e=l(t),r=t-e;return.5>r?e:r>.5?e+1:e%2?e+1:e}var i,o,u,c,p,b,y,v=(1<t?1:0):0===t?(o=0,u=0,i=1/t===-(1/0)?1:0):(i=0>t,t=s(t),t>=m(2,1-v)?(o=h(l(f(t)/a),1023),u=n(t/m(2,o)*m(2,r)),u/m(2,r)>=2&&(o+=1,u=1),o>v?(o=(1<>=1;return f.reverse(),u=f.join(""),c=(1<0?a*m(2,s-c)*(1+l/m(2,r)):0!==l?a*m(2,-(c-1))*(l/m(2,r)):0>a?-0:0}function r(t){return e(t,8,23)}function n(e){return t(e,8,23)}function i(t){return 0===t||!o(t)||u(t)?t:r(n(Number(t)))}var o=isFinite,u=isNaN,c=Math,a=c.LN2,s=c.abs,l=c.floor,f=c.log,h=c.min,m=c.pow;return{get fround(){return i}}}),System.registerModule("traceur-runtime@0.0.87/src/runtime/polyfills/Math.js",[],function(){"use strict";function t(t){if(t=S(+t),0==t)return 32;var e=0;return 0===(4294901760&t)&&(t<<=16,e+=16),0===(4278190080&t)&&(t<<=8,e+=8),0===(4026531840&t)&&(t<<=4,e+=4),0===(3221225472&t)&&(t<<=2,e+=2),0===(2147483648&t)&&(t<<=1,e+=1),e}function e(t,e){t=S(+t),e=S(+e);var r=t>>>16&65535,n=65535&t,i=e>>>16&65535,o=65535&e;return n*o+(r*o+n*i<<16>>>0)|0}function r(t){return t=+t,t>0?1:0>t?-1:t}function n(t){return.4342944819032518*k(t)}function i(t){return 1.4426950408889634*k(t)}function o(t){if(t=+t,-1>t||_(t))return 0/0;if(0===t||t===1/0)return t;if(t===-1)return-(1/0);var e=0,r=50;if(0>t||t>1)return k(1+t);for(var n=1;r>n;n++)n%2===0?e-=I(t,n)/n:e+=I(t,n)/n;return e}function u(t){return t=+t,t===-(1/0)?-1:R(t)&&0!==t?$(t)-1:t}function c(t){return t=+t,0===t?1:_(t)?0/0:R(t)?(0>t&&(t=-t),t>21?$(t)/2:($(t)+$(-t))/2):1/0}function a(t){return t=+t,R(t)&&0!==t?($(t)-$(-t))/2:t}function s(t){if(t=+t,0===t)return t;if(!R(t))return r(t);var e=$(t),n=$(-t);return(e-n)/(e+n)}function l(t){return t=+t,1>t?0/0:R(t)?k(t+T(t+1)*T(t-1)):t}function f(t){return t=+t,0!==t&&R(t)?t>0?k(t+T(t*t+1)):-k(-t+T(t*t+1)):t}function h(t){return t=+t,t===-1?-(1/0):1===t?1/0:0===t?t:_(t)||-1>t||t>1?0/0:.5*k((1+t)/(1-t))}function m(){for(var t=arguments.length,e=new Array(t),r=0,n=0;t>n;n++){var i=arguments[n];if(i=+i,i===1/0||i===-(1/0))return 1/0;i=P(i),i>r&&(r=i),e[n]=i}0===r&&(r=1);for(var o=0,u=0,n=0;t>n;n++){var i=e[n]/r,c=i*i-u,a=o+c;u=a-o-c,o=a}return T(o)*r}function p(t){return t=+t,t>0?E(t):0>t?M(t):t}function b(t){if(t=+t,0===t)return t;var e=0>t;e&&(t=-t);var r=I(t,1/3);return e?-r:r}function y(y){var g=y.Math;w(g,["acosh",l,"asinh",f,"atanh",h,"cbrt",b,"clz32",t,"cosh",c,"expm1",u,"fround",v,"hypot",m,"imul",e,"log10",n,"log1p",o,"log2",i,"sign",r,"sinh",a,"tanh",s,"trunc",p])}var v,g,d=System.get("traceur-runtime@0.0.87/src/runtime/polyfills/fround.js").fround,j=System.get("traceur-runtime@0.0.87/src/runtime/polyfills/utils.js"),w=j.maybeAddFunctions,O=j.registerPolyfill,S=j.toUint32,R=isFinite,_=isNaN,x=Math,P=x.abs,M=x.ceil,$=x.exp,E=x.floor,k=x.log,I=x.pow,T=x.sqrt;return"function"==typeof Float32Array?(g=new Float32Array(1),v=function(t){return g[0]=Number(t),g[0]}):v=d,O(y),{get clz32(){return t},get imul(){return e},get sign(){return r},get log10(){return n},get log2(){return i},get log1p(){return o},get expm1(){return u},get cosh(){return c},get sinh(){return a},get tanh(){return s},get acosh(){return l},get asinh(){return f},get atanh(){return h},get hypot(){return m},get trunc(){return p},get fround(){return v},get cbrt(){return b},get polyfillMath(){return y}}}),System.get("traceur-runtime@0.0.87/src/runtime/polyfills/Math.js"+""),System.registerModule("traceur-runtime@0.0.87/src/runtime/polyfills/polyfills.js",[],function(){"use strict";var t=System.get("traceur-runtime@0.0.87/src/runtime/polyfills/utils.js").polyfillAll;t(Reflect.global);var e=$traceurRuntime.setupGlobals;return $traceurRuntime.setupGlobals=function(r){e(r),t(r)},{}}),System.get("traceur-runtime@0.0.87/src/runtime/polyfills/polyfills.js"+""); 4 | //# sourceMappingURL=traceur-runtime.js.map -------------------------------------------------------------------------------- /login.html: -------------------------------------------------------------------------------- 1 |
2 | 3 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | {{username}}/{{password}} 12 |
-------------------------------------------------------------------------------- /shell.html: -------------------------------------------------------------------------------- 1 | Hello {{user}}! -------------------------------------------------------------------------------- /tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "sourceMap": true, 4 | "module": "commonjs", 5 | "target": "ES5", 6 | "emitDecoratorMetadata": true 7 | }, 8 | "files": [ 9 | "lib/angular2.d.ts", 10 | "app.ts" 11 | ] 12 | } --------------------------------------------------------------------------------