Socket
Socket
Sign inDemoInstall

systemjs

Package Overview
Dependencies
Maintainers
1
Versions
236
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

systemjs - npm Package Compare versions

Comparing version 6.3.3 to 6.4.0

dist/extras/dynamic-import-maps.js

7

CHANGELOG.md

@@ -0,1 +1,8 @@

SystemJS 6.4.0
* Dynamic import map extra support (https://github.com/systemjs/systemjs/pull/2217 @stevenvachon)
* Depcache support in import maps for automated preloading (https://github.com/systemjs/systemjs/pull/2134)
* Auto Import feature for `<script src="system-register-module.js">` loading for better load performance (https://github.com/systemjs/systemjs/pull/2216, https://github.com/systemjs/systemjs/pull/2210 @tmsns)
* Fix onload behaviour with flag for error source (https://github.com/systemjs/systemjs/pull/2204 @smartrejames)
* Fix Object.prototype mutation (https://github.com/systemjs/systemjs/pull/2206 @stevenvachon)
SystemJS 6.3.3

@@ -2,0 +9,0 @@ * Better error message when content-type header is missing (https://github.com/systemjs/systemjs/pull/2197 via @brandones)

2

dist/extras/global.js

@@ -7,3 +7,3 @@ (function(){/*

(function (global) {
var systemJSPrototype = System.constructor.prototype;
var systemJSPrototype = global.System.constructor.prototype;

@@ -10,0 +10,0 @@ // safari unpredictably lists some new globals first or second in object order

@@ -1,1 +0,1 @@

!function(n){function t(t){return!n.hasOwnProperty(t)||!isNaN(t)&&n.length>t||c&&n[t]&&"undefined"!=typeof window&&n[t].parent===window}var r,e,i,u=System.constructor.prototype,f=u.import;u.import=function(u,o){return function(){for(var u in r=e=void 0,n)t(u)||(r?e||(e=u):r=u,i=u)}(),f.call(this,u,o)};var o=[[],function(){return{}}],a=u.getRegister;u.getRegister=function(){var u=a.call(this);if(u)return u;var f,c=function(){var u,f=0;for(var o in n)if(!t(o)){if(0===f&&o!==r||1===f&&o!==e)return o;f++,u=o}if(u!==i)return u}();if(!c)return o;try{f=n[c]}catch(d){return o}return[[],function(n){return{execute:function(){n({default:f,__useDefault:!0})}}}]};var c="undefined"!=typeof navigator&&-1!==navigator.userAgent.indexOf("Trident")}("undefined"!=typeof self?self:global);//# sourceMappingURL=global.min.js.map
!function(n){function t(t){return!n.hasOwnProperty(t)||!isNaN(t)&&n.length>t||c&&n[t]&&"undefined"!=typeof window&&n[t].parent===window}var r,e,i,u=n.System.constructor.prototype,f=u.import;u.import=function(u,o){return function(){for(var u in r=e=void 0,n)t(u)||(r?e||(e=u):r=u,i=u)}(),f.call(this,u,o)};var o=[[],function(){return{}}],a=u.getRegister;u.getRegister=function(){var u=a.call(this);if(u)return u;var f,c=function(){var u,f=0;for(var o in n)if(!t(o)){if(0===f&&o!==r||1===f&&o!==e)return o;f++,u=o}if(u!==i)return u}();if(!c)return o;try{f=n[c]}catch(d){return o}return[[],function(n){return{execute:function(){n({default:f,__useDefault:!0})}}}]};var c="undefined"!=typeof navigator&&-1!==navigator.userAgent.indexOf("Trident")}("undefined"!=typeof self?self:global);//# sourceMappingURL=global.min.js.map
/*
* SJS 6.3.3
* SJS 6.4.0
* Minimal SystemJS Build

@@ -130,2 +130,4 @@ */

var IMPORT_MAP = hasSymbol ? Symbol() : '#';
function resolveAndComposePackages (packages, outPackages, baseUrl, parentMap, parentUrl) {

@@ -148,3 +150,3 @@ for (var p in packages) {

function resolveAndComposeImportMap (json, baseUrl, parentMap) {
var outMap = { imports: objectAssign({}, parentMap.imports), scopes: objectAssign({}, parentMap.scopes) };
var outMap = { imports: objectAssign({}, parentMap.imports), scopes: objectAssign({}, parentMap.scopes), depcache: objectAssign({}, parentMap.depcache) };

@@ -160,2 +162,8 @@ if (json.imports)

if (json.depcache)
for (var d in json.depcache) {
var resolvedDepcache = resolveUrl(d, baseUrl);
outMap.depcache[resolvedDepcache] = json.depcache[d];
}
return outMap;

@@ -251,4 +259,4 @@ }

}
function triggerOnload (loader, load, err) {
loader.onload(err, load.id, load.d && load.d.map(loadToId));
function triggerOnload (loader, load, err, isErrSource) {
loader.onload(err, load.id, load.d && load.d.map(loadToId), !!isErrSource);
if (err)

@@ -350,5 +358,8 @@ throw err;

}))
.then(function (depLoads) {
load.d = depLoads;
});
.then(
function (depLoads) {
load.d = depLoads;
},
!true
)
});

@@ -442,17 +453,19 @@

load.d.forEach(function (depLoad) {
if (false) {
try {
var depLoadPromise;
var depLoadPromise = postOrderExec(loader, depLoad, seen);
if (depLoadPromise)
(depLoadPromises = depLoadPromises || []).push(depLoadPromise);
}
catch (err) {
load.e = null;
load.er = err;
throw err;
}
}
else {
var depLoadPromise = postOrderExec(loader, depLoad, seen);
if (depLoadPromise)
(depLoadPromises = depLoadPromises || []).push(depLoadPromise);
}
});
if (depLoadPromises)
return Promise.all(depLoadPromises).then(doExec);
return Promise.all(depLoadPromises).then(doExec, function (err) {
load.e = null;
load.er = err;
throw err;
});

@@ -465,14 +478,11 @@ return doExec();

if (execPromise) {
if (!true)
execPromise = execPromise.then(function () {
load.C = load.n;
load.E = null; // indicates completion
triggerOnload(loader, load, null);
if (!true) triggerOnload(loader, load, null, true);
}, function (err) {
triggerOnload(loader, load, err);
});
else
execPromise = execPromise.then(function () {
load.C = load.n;
load.er = err;
load.E = null;
if (!true) triggerOnload(loader, load, err, true);
else throw err;
});

@@ -483,3 +493,3 @@ return load.E = load.E || execPromise;

load.C = load.n;
if (!true) triggerOnload(loader, load, null);
if (!true) triggerOnload(loader, load, null, true);
}

@@ -500,70 +510,5 @@ catch (err) {

/*
* Import map support for SystemJS
*
* <script type="systemjs-importmap">{}</script>
* OR
* <script type="systemjs-importmap" src=package.json></script>
*
* Only those import maps available at the time of SystemJS initialization will be loaded
* and they will be loaded in DOM order.
*
* There is no support for dynamic import maps injection currently.
* Script instantiation loading
*/
var IMPORT_MAP = hasSymbol ? Symbol() : '#';
var IMPORT_MAP_PROMISE = hasSymbol ? Symbol() : '$';
iterateDocumentImportMaps(function (script) {
script._t = fetch(script.src).then(function (res) {
return res.text();
});
}, '[src]');
systemJSPrototype.prepareImport = function () {
var loader = this;
if (!loader[IMPORT_MAP_PROMISE]) {
loader[IMPORT_MAP] = { imports: {}, scopes: {} };
loader[IMPORT_MAP_PROMISE] = Promise.resolve();
iterateDocumentImportMaps(function (script) {
loader[IMPORT_MAP_PROMISE] = loader[IMPORT_MAP_PROMISE].then(function () {
return (script._t || script.src && fetch(script.src).then(function (res) { return res.text(); }) || Promise.resolve(script.innerHTML))
.then(function (text) {
try {
return JSON.parse(text);
} catch (err) {
throw Error( errMsg(1) );
}
})
.then(function (newMap) {
loader[IMPORT_MAP] = resolveAndComposeImportMap(newMap, script.src || baseUrl, loader[IMPORT_MAP]);
});
});
}, '');
}
return loader[IMPORT_MAP_PROMISE];
};
systemJSPrototype.resolve = function (id, parentUrl) {
parentUrl = parentUrl || !true || baseUrl;
return resolveImportMap(this[IMPORT_MAP], resolveIfNotPlainOrUrl(id, parentUrl) || id, parentUrl) || throwUnresolved(id, parentUrl);
};
function throwUnresolved (id, parentUrl) {
throw Error(errMsg(8, [id, parentUrl].join(', ') ));
}
function iterateDocumentImportMaps(cb, extraSelector) {
if (hasDocument)
[].forEach.call(document.querySelectorAll('script[type="systemjs-importmap"]' + extraSelector), cb);
}
/*
* Supports loading System.register via script tag injection
*/
var systemRegister = systemJSPrototype.register;
systemJSPrototype.register = function (deps, declare) {
systemRegister.call(this, deps, declare);
};
systemJSPrototype.createScript = function (url) {

@@ -601,3 +546,3 @@ var script = document.createElement('script');

if (hasDocument) {
if (hasDocument)
window.addEventListener('error', function (evt) {

@@ -608,16 +553,123 @@ lastWindowErrorUrl = evt.filename;

window.addEventListener('DOMContentLoaded', loadScriptModules);
loadScriptModules();
systemJSPrototype.resolve = function (id, parentUrl) {
parentUrl = parentUrl || !true || baseUrl;
return resolveImportMap(this[IMPORT_MAP], resolveIfNotPlainOrUrl(id, parentUrl) || id, parentUrl) || throwUnresolved(id, parentUrl);
};
function throwUnresolved (id, parentUrl) {
throw Error(errMsg(8, [id, parentUrl].join(', ') ));
}
/*
* SystemJS browser attachments for script and import map processing
*/
function loadScriptModules() {
[].forEach.call(
document.querySelectorAll('script[type=systemjs-module]'), function (script) {
if (script.src) {
System.import(script.src.slice(0, 7) === 'import:' ? script.src.slice(7) : resolveUrl(script.src, baseUrl));
}
});
var importMapPromise = Promise.resolve({ imports: {}, scopes: {}, depcache: {} });
// Scripts are processed immediately, on the first System.import, and on DOMReady.
// Import map scripts are processed only once (by being marked) and in order for each phase.
// This is to avoid using DOM mutation observers in core, although that would be an alternative.
var processFirst = hasDocument;
systemJSPrototype.prepareImport = function (doProcessScripts) {
if (processFirst || doProcessScripts) {
processScripts();
processFirst = false;
}
var loader = this;
return importMapPromise.then(function (importMap) {
loader[IMPORT_MAP] = importMap;
});
};
if (hasDocument) {
processScripts();
window.addEventListener('DOMContentLoaded', processScripts);
}
const systemInstantiate = systemJSPrototype.instantiate;
systemJSPrototype.instantiate = function (url, firstParentUrl) {
var preloads = this[IMPORT_MAP].depcache[url];
if (preloads) {
for (var i = 0; i < preloads.length; i++)
getOrCreateLoad(this, this.resolve(preloads[i], url), url);
}
return systemInstantiate.call(this, url, firstParentUrl);
};
function processScripts () {
[].forEach.call(document.querySelectorAll('script'), function (script) {
if (script.sp) // sp marker = systemjs processed
return;
// TODO: deprecate systemjs-module in next major now that we have auto import
if (script.type === 'systemjs-module') {
script.sp = true;
if (!script.src)
return;
System.import(script.src.slice(0, 7) === 'import:' ? script.src.slice(7) : resolveUrl(script.src, baseUrl));
}
else if (script.type === 'systemjs-importmap') {
script.sp = true;
importMapPromise = importMapPromise.then(function (importMap) {
if (script.src)
return fetch(script.src).then(function (res) {
return res.text();
}).then(function (text) {
return extendImportMap(importMap, text, script.src);
});
return extendImportMap(importMap, script.innerHTML, baseUrl);
});
}
});
}
function extendImportMap (importMap, newMapText, newMapUrl) {
try {
var newMap = JSON.parse(newMapText);
} catch (err) {
throw Error( errMsg(1) );
}
return resolveAndComposeImportMap(newMap, newMapUrl, importMap);
}
/**
* Auto-import <script src="system-module.js"></script> registrations
* Allows the browser preloader to work directly with SystemJS optimization
*/
var autoImports = {};
var systemRegister = systemJSPrototype.register;
systemJSPrototype.register = function (deps, declare) {
if (hasDocument && document.readyState === 'loading' && typeof deps !== 'string') {
var scripts = document.getElementsByTagName('script');
var lastScript = scripts[scripts.length - 1];
if (lastScript && lastScript.src) {
// Only import if not already in the registry.
// This avoids re-importing an inline dynamic System.import dependency.
// There is still a risk if a user dynamically injects a custom System.register script during DOM load that does an
// anomymous registration that is able to execute before DOM load completion, and thus is incorrectly matched to the
// last script when it wasn't causing a System.import of that last script, but this is deemed an acceptable edge case
// since due to custom user registration injection.
// Not using document.currentScript is done to ensure IE11 equivalence.
if (!this[REGISTRY][lastScript.src]) {
autoImports[lastScript.src] = [deps, declare];
// Auto import = immediately import the registration
// It is up to the user to manage execution order for deep preloading.
this.import(lastScript.src);
}
return;
}
}
return systemRegister.call(this, deps, declare);
};
var systemInstantiate$1 = systemJSPrototype.instantiate;
systemJSPrototype.instantiate = function (url) {
var autoImport = autoImports[url];
if (autoImport) {
delete autoImports[url];
return autoImport;
}
return systemInstantiate$1.apply(this, arguments);
};
/*

@@ -624,0 +676,0 @@ * Supports loading System.register in workers

@@ -1,2 +0,2 @@

!function(){function e(e,n){return(n||"")+" (SystemJS https://git.io/JvFET#"+e+")"}function n(e,n){if(-1!==e.indexOf("\\")&&(e=e.replace(/\\/g,"/")),"/"===e[0]&&"/"===e[1])return n.slice(0,n.indexOf(":")+1)+e;if("."===e[0]&&("/"===e[1]||"."===e[1]&&("/"===e[2]||2===e.length&&(e+="/"))||1===e.length&&(e+="/"))||"/"===e[0]){var t,r=n.slice(0,n.indexOf(":")+1);if(t="/"===n[r.length+1]?"file:"!==r?(t=n.slice(r.length+2)).slice(t.indexOf("/")+1):n.slice(8):n.slice(r.length+("/"===n[r.length])),"/"===e[0])return n.slice(0,n.length-t.length-1)+e;for(var i=t.slice(0,t.lastIndexOf("/")+1)+e,o=[],c=-1,u=0;i.length>u;u++)-1!==c?"/"===i[u]&&(o.push(i.slice(c,u+1)),c=-1):"."===i[u]?"."!==i[u+1]||"/"!==i[u+2]&&u+2!==i.length?"/"===i[u+1]||u+1===i.length?u+=1:c=u:(o.pop(),u+=2):c=u;return-1!==c&&o.push(i.slice(c)),n.slice(0,n.length-t.length)+o.join("")}}function t(e,t){return n(e,t)||(-1!==e.indexOf(":")?e:n("./"+e,t))}function r(e,n){for(var t in n)e[t]=n[t];return e}function i(e,t,r,i,o){for(var c in e){var f=n(c,r)||c,l=e[c];if("string"==typeof l){var a=s(i,n(l,r)||l,o);a?t[f]=a:u("W1",c,l)}}}function o(e,n){if(n[e])return e;var t=e.length;do{var r=e.slice(0,t+1);if(r in n)return r}while(-1!==(t=e.lastIndexOf("/",t-1)))}function c(e,n){var t=o(e,n);if(t){var r=n[t];if(null===r)return;if(t.length>=e.length||"/"===r[r.length-1])return r+e.slice(t.length);u("W2",t,r)}}function u(n,t,r){console.warn(e(n,[r,t].join(", ")))}function s(e,n,t){for(var r=e.scopes,i=t&&o(t,r);i;){var u=c(n,r[i]);if(u)return u;i=o(i.slice(0,i.lastIndexOf("/")),r)}return c(n,e.imports)||-1!==n.indexOf(":")&&n}function f(){this[O]={}}function l(e,n){p&&[].forEach.call(document.querySelectorAll('script[type="systemjs-importmap"]'+n),e)}function a(){[].forEach.call(document.querySelectorAll("script[type=systemjs-module]"),(function(e){e.src&&System.import("import:"===e.src.slice(0,7)?e.src.slice(7):t(e.src,h))}))}var h,v="undefined"!=typeof Symbol,d="undefined"!=typeof self,p="undefined"!=typeof document,m=d?self:global;if(p){var g=document.querySelector("base[href]");g&&(h=g.href)}if(!h&&"undefined"!=typeof location){var y=(h=location.href.split("#")[0].split("?")[0]).lastIndexOf("/");-1!==y&&(h=h.slice(0,y+1))}var E,S=v&&Symbol.toStringTag,O=v?Symbol():"@",x=f.prototype;x.import=function(n,t){var r=this;return Promise.resolve(r.prepareImport()).then((function(){return r.resolve(n,t)})).then((function(n){var t=function n(t,r,i){var o=t[O][r];if(o)return o;var c=[],u=Object.create(null);S&&Object.defineProperty(u,S,{value:"Module"});var s=Promise.resolve().then((function(){return t.instantiate(r,i)})).then((function(n){if(!n)throw Error(e(2,r));var i=n[1]((function(e,n){o.h=!0;var t=!1;if("object"!=typeof e)e in u&&u[e]===n||(u[e]=n,t=!0);else{for(var r in e)n=e[r],r in u&&u[r]===n||(u[r]=n,t=!0);e.__esModule&&(u.__esModule=e.__esModule)}if(t)for(var i=0;c.length>i;i++){var s=c[i];s&&s(u)}return n}),2===n[1].length?{import:function(e){return t.import(e,r)},meta:t.createContext(r)}:void 0);return o.e=i.execute||function(){},[n[0],i.setters||[]]})),f=s.then((function(e){return Promise.all(e[0].map((function(i,o){var c=e[1][o];return Promise.resolve(t.resolve(i,r)).then((function(e){var i=n(t,e,r);return Promise.resolve(i.I).then((function(){return c&&(i.i.push(c),!i.h&&i.I||c(i.n)),i}))}))}))).then((function(e){o.d=e}))}));return f.catch((function(e){o.e=null,o.er=e})),o=t[O][r]={id:r,i:c,n:u,I:s,L:f,h:!1,d:void 0,e:void 0,er:void 0,E:void 0,C:void 0}}(r,n);return t.C||function(e,n){return n.C=function e(n,t,r){if(!r[t.id])return r[t.id]=!0,Promise.resolve(t.L).then((function(){return Promise.all(t.d.map((function(t){return e(n,t,r)})))}))}(e,n,{}).then((function(){return function e(n,t,r){function i(){try{var e=t.e.call(w);if(e)return e=e.then((function(){t.C=t.n,t.E=null})),t.E=t.E||e;t.C=t.n}catch(n){throw t.er=n,n}finally{t.L=t.I=void 0,t.e=null}}if(!r[t.id]){if(r[t.id]=!0,!t.e){if(t.er)throw t.er;return t.E?t.E:void 0}var o;return t.d.forEach((function(t){var i;(i=e(n,t,r))&&(o=o||[]).push(i)})),o?Promise.all(o).then(i):i()}}(e,n,{})})).then((function(){return n.n}))}(r,t)}))},x.createContext=function(e){return{url:e}},x.register=function(e,n){E=[e,n]},x.getRegister=function(){var e=E;return E=void 0,e};var w=Object.freeze(Object.create(null));m.System=new f;var P=v?Symbol():"#",b=v?Symbol():"$";l((function(e){e._t=fetch(e.src).then((function(e){return e.text()}))}),"[src]"),x.prepareImport=function(){var n=this;return n[b]||(n[P]={imports:{},scopes:{}},n[b]=Promise.resolve(),l((function(o){n[b]=n[b].then((function(){return(o._t||o.src&&fetch(o.src).then((function(e){return e.text()}))||Promise.resolve(o.innerHTML)).then((function(n){try{return JSON.parse(n)}catch(t){throw Error(e(1))}})).then((function(e){n[P]=function(e,n,o){var c={imports:r({},o.imports),scopes:r({},o.scopes)};if(e.imports&&i(e.imports,c.imports,n,o,null),e.scopes)for(var u in e.scopes){var s=t(u,n);i(e.scopes[u],c.scopes[s]||(c.scopes[s]={}),n,o,s)}return c}(e,o.src||h,n[P])}))}))}),"")),n[b]},x.resolve=function(t,r){return s(this[P],n(t,r=r||h)||t,r)||function(n,t){throw Error(e(8,[n,t].join(", ")))}(t,r)};var j,C,I=x.register;x.register=function(e,n){I.call(this,e,n)},x.createScript=function(e){var n=document.createElement("script");return n.charset="utf-8",n.async=!0,n.crossOrigin="anonymous",n.src=e,n},x.instantiate=function(n,t){var r=this;return new Promise((function(i,o){var c=x.createScript(n);c.addEventListener("error",(function(){o(Error(e(3,[n,t].join(", "))))})),c.addEventListener("load",(function(){document.head.removeChild(c),j===n?o(C):i(r.getRegister())})),document.head.appendChild(c)}))},p&&(window.addEventListener("error",(function(e){j=e.filename,C=e.error})),window.addEventListener("DOMContentLoaded",a),a()),d&&"function"==typeof importScripts&&(x.instantiate=function(e){var n=this;return Promise.resolve().then((function(){return importScripts(e),n.getRegister()}))})}();
!function(){function e(e,t){return(t||"")+" (SystemJS https://git.io/JvFET#"+e+")"}function t(e,t){if(-1!==e.indexOf("\\")&&(e=e.replace(/\\/g,"/")),"/"===e[0]&&"/"===e[1])return t.slice(0,t.indexOf(":")+1)+e;if("."===e[0]&&("/"===e[1]||"."===e[1]&&("/"===e[2]||2===e.length&&(e+="/"))||1===e.length&&(e+="/"))||"/"===e[0]){var n,r=t.slice(0,t.indexOf(":")+1);if(n="/"===t[r.length+1]?"file:"!==r?(n=t.slice(r.length+2)).slice(n.indexOf("/")+1):t.slice(8):t.slice(r.length+("/"===t[r.length])),"/"===e[0])return t.slice(0,t.length-n.length-1)+e;for(var i=n.slice(0,n.lastIndexOf("/")+1)+e,o=[],c=-1,s=0;i.length>s;s++)-1!==c?"/"===i[s]&&(o.push(i.slice(c,s+1)),c=-1):"."===i[s]?"."!==i[s+1]||"/"!==i[s+2]&&s+2!==i.length?"/"===i[s+1]||s+1===i.length?s+=1:c=s:(o.pop(),s+=2):c=s;return-1!==c&&o.push(i.slice(c)),t.slice(0,t.length-n.length)+o.join("")}}function n(e,n){return t(e,n)||(-1!==e.indexOf(":")?e:t("./"+e,n))}function r(e,t){for(var n in t)e[n]=t[n];return e}function i(e,n,r,i,o){for(var c in e){var f=t(c,r)||c,a=e[c];if("string"==typeof a){var l=u(i,t(a,r)||a,o);l?n[f]=l:s("W1",c,a)}}}function o(e,t){if(t[e])return e;var n=e.length;do{var r=e.slice(0,n+1);if(r in t)return r}while(-1!==(n=e.lastIndexOf("/",n-1)))}function c(e,t){var n=o(e,t);if(n){var r=t[n];if(null===r)return;if(n.length>=e.length||"/"===r[r.length-1])return r+e.slice(n.length);s("W2",n,r)}}function s(t,n,r){console.warn(e(t,[r,n].join(", ")))}function u(e,t,n){for(var r=e.scopes,i=n&&o(n,r);i;){var s=c(t,r[i]);if(s)return s;i=o(i.slice(0,i.lastIndexOf("/")),r)}return c(t,e.imports)||-1!==t.indexOf(":")&&t}function f(){this[x]={}}function a(t,n,r){var i=t[x][n];if(i)return i;var o=[],c=Object.create(null);w&&Object.defineProperty(c,w,{value:"Module"});var s=Promise.resolve().then((function(){return t.instantiate(n,r)})).then((function(r){if(!r)throw Error(e(2,n));var s=r[1]((function(e,t){i.h=!0;var n=!1;if("object"!=typeof e)e in c&&c[e]===t||(c[e]=t,n=!0);else{for(var r in e)t=e[r],r in c&&c[r]===t||(c[r]=t,n=!0);e.__esModule&&(c.__esModule=e.__esModule)}if(n)for(var s=0;o.length>s;s++){var u=o[s];u&&u(c)}return t}),2===r[1].length?{import:function(e){return t.import(e,n)},meta:t.createContext(n)}:void 0);return i.e=s.execute||function(){},[r[0],s.setters||[]]})),u=s.then((function(e){return Promise.all(e[0].map((function(r,i){var o=e[1][i];return Promise.resolve(t.resolve(r,n)).then((function(e){var r=a(t,e,n);return Promise.resolve(r.I).then((function(){return o&&(r.i.push(o),!r.h&&r.I||o(r.n)),r}))}))}))).then((function(e){i.d=e}),!1)}));return u.catch((function(e){i.e=null,i.er=e})),i=t[x][n]={id:n,i:o,n:c,I:s,L:u,h:!1,d:void 0,e:void 0,er:void 0,E:void 0,C:void 0}}function l(){[].forEach.call(document.querySelectorAll("script"),(function(e){if(!e.sp)if("systemjs-module"===e.type){if(e.sp=!0,!e.src)return;System.import("import:"===e.src.slice(0,7)?e.src.slice(7):n(e.src,d))}else"systemjs-importmap"===e.type&&(e.sp=!0,I=I.then((function(t){return e.src?fetch(e.src).then((function(e){return e.text()})).then((function(n){return h(t,n,e.src)})):h(t,e.innerHTML,d)})))}))}function h(t,o,c){try{var s=JSON.parse(o)}catch(u){throw Error(e(1))}return function(e,t,o){var c={imports:r({},o.imports),scopes:r({},o.scopes),depcache:r({},o.depcache)};if(e.imports&&i(e.imports,c.imports,t,o,null),e.scopes)for(var s in e.scopes){var u=n(s,t);i(e.scopes[s],c.scopes[u]||(c.scopes[u]={}),t,o,u)}if(e.depcache)for(var f in e.depcache){var a=n(f,t);c.depcache[a]=e.depcache[f]}return c}(s,c,t)}var d,p="undefined"!=typeof Symbol,v="undefined"!=typeof self,m="undefined"!=typeof document,g=v?self:global;if(m){var y=document.querySelector("base[href]");y&&(d=y.href)}if(!d&&"undefined"!=typeof location){var E=(d=location.href.split("#")[0].split("?")[0]).lastIndexOf("/");-1!==E&&(d=d.slice(0,E+1))}var O,S=p?Symbol():"#",w=p&&Symbol.toStringTag,x=p?Symbol():"@",P=f.prototype;P.import=function(e,t){var n=this;return Promise.resolve(n.prepareImport()).then((function(){return n.resolve(e,t)})).then((function(e){var t=a(n,e);return t.C||function(e,t){return t.C=function e(t,n,r){if(!r[n.id])return r[n.id]=!0,Promise.resolve(n.L).then((function(){return Promise.all(n.d.map((function(n){return e(t,n,r)})))}))}(e,t,{}).then((function(){return function e(t,n,r){function i(){try{var e=n.e.call(C);if(e)return e=e.then((function(){n.C=n.n,n.E=null}),(function(e){throw n.er=e,n.E=null,e})),n.E=n.E||e;n.C=n.n}catch(t){throw n.er=t,t}finally{n.L=n.I=void 0,n.e=null}}if(!r[n.id]){if(r[n.id]=!0,!n.e){if(n.er)throw n.er;return n.E?n.E:void 0}var o;return n.d.forEach((function(i){try{var c=e(t,i,r);c&&(o=o||[]).push(c)}catch(s){throw n.e=null,n.er=s,s}})),o?Promise.all(o).then(i,(function(e){throw n.e=null,n.er=e,e})):i()}}(e,t,{})})).then((function(){return t.n}))}(n,t)}))},P.createContext=function(e){return{url:e}},P.register=function(e,t){O=[e,t]},P.getRegister=function(){var e=O;return O=void 0,e};var b,j,C=Object.freeze(Object.create(null));g.System=new f,P.createScript=function(e){var t=document.createElement("script");return t.charset="utf-8",t.async=!0,t.crossOrigin="anonymous",t.src=e,t},P.instantiate=function(t,n){var r=this;return new Promise((function(i,o){var c=P.createScript(t);c.addEventListener("error",(function(){o(Error(e(3,[t,n].join(", "))))})),c.addEventListener("load",(function(){document.head.removeChild(c),b===t?o(j):i(r.getRegister())})),document.head.appendChild(c)}))},m&&window.addEventListener("error",(function(e){b=e.filename,j=e.error})),P.resolve=function(n,r){return u(this[S],t(n,r=r||d)||n,r)||function(t,n){throw Error(e(8,[t,n].join(", ")))}(n,r)};var I=Promise.resolve({imports:{},scopes:{},depcache:{}}),L=m;P.prepareImport=function(e){(L||e)&&(l(),L=!1);var t=this;return I.then((function(e){t[S]=e}))},m&&(l(),window.addEventListener("DOMContentLoaded",l));const M=P.instantiate;P.instantiate=function(e,t){var n=this[S].depcache[e];if(n)for(var r=0;n.length>r;r++)a(this,this.resolve(n[r],e),e);return M.call(this,e,t)};var _={},T=P.register;P.register=function(e,t){if(m&&"loading"===document.readyState&&"string"!=typeof e){var n=document.getElementsByTagName("script"),r=n[n.length-1];if(r&&r.src)return void(this[x][r.src]||(_[r.src]=[e,t],this.import(r.src)))}return T.call(this,e,t)};var J=P.instantiate;P.instantiate=function(e){var t=_[e];return t?(delete _[e],t):J.apply(this,arguments)},v&&"function"==typeof importScripts&&(P.instantiate=function(e){var t=this;return Promise.resolve().then((function(){return importScripts(e),t.getRegister()}))})}();
//# sourceMappingURL=s.min.js.map
/*
* SystemJS 6.3.3
* SystemJS 6.4.0
*/

@@ -129,2 +129,4 @@ (function () {

var IMPORT_MAP = hasSymbol ? Symbol() : '#';
function resolveAndComposePackages (packages, outPackages, baseUrl, parentMap, parentUrl) {

@@ -147,3 +149,3 @@ for (var p in packages) {

function resolveAndComposeImportMap (json, baseUrl, parentMap) {
var outMap = { imports: objectAssign({}, parentMap.imports), scopes: objectAssign({}, parentMap.scopes) };
var outMap = { imports: objectAssign({}, parentMap.imports), scopes: objectAssign({}, parentMap.scopes), depcache: objectAssign({}, parentMap.depcache) };

@@ -159,2 +161,8 @@ if (json.imports)

if (json.depcache)
for (var d in json.depcache) {
var resolvedDepcache = resolveUrl(d, baseUrl);
outMap.depcache[resolvedDepcache] = json.depcache[d];
}
return outMap;

@@ -253,4 +261,4 @@ }

}
function triggerOnload (loader, load, err) {
loader.onload(err, load.id, load.d && load.d.map(loadToId));
function triggerOnload (loader, load, err, isErrSource) {
loader.onload(err, load.id, load.d && load.d.map(loadToId), !!isErrSource);
if (err)

@@ -332,3 +340,3 @@ throw err;

instantiatePromise = instantiatePromise.catch(function (err) {
triggerOnload(loader, load, err);
triggerOnload(loader, load, err, true);
});

@@ -357,5 +365,10 @@

}))
.then(function (depLoads) {
load.d = depLoads;
});
.then(
function (depLoads) {
load.d = depLoads;
},
function (err) {
triggerOnload(loader, load, err, false);
}
)
});

@@ -449,22 +462,19 @@

load.d.forEach(function (depLoad) {
if (true) {
try {
var depLoadPromise = postOrderExec(loader, depLoad, seen);
if (depLoadPromise) {
depLoadPromise.catch(function (err) {
triggerOnload(loader, load, err);
});
if (depLoadPromise)
(depLoadPromises = depLoadPromises || []).push(depLoadPromise);
}
}
catch (err) {
triggerOnload(loader, load, err);
load.e = null;
load.er = err;
triggerOnload(loader, load, err, false);
}
}
else {
var depLoadPromise;
}
});
if (depLoadPromises)
return Promise.all(depLoadPromises).then(doExec);
return Promise.all(depLoadPromises).then(doExec, function (err) {
load.e = null;
load.er = err;
triggerOnload(loader, load, err, false);
});

@@ -477,14 +487,11 @@ return doExec();

if (execPromise) {
if (!false)
execPromise = execPromise.then(function () {
load.C = load.n;
load.E = null; // indicates completion
triggerOnload(loader, load, null);
if (!false) triggerOnload(loader, load, null, true);
}, function (err) {
triggerOnload(loader, load, err);
});
else
execPromise = execPromise.then(function () {
load.C = load.n;
load.er = err;
load.E = null;
if (!false) triggerOnload(loader, load, err, true);
else throw err;
});

@@ -495,7 +502,7 @@ return load.E = load.E || execPromise;

load.C = load.n;
if (!false) triggerOnload(loader, load, null);
if (!false) triggerOnload(loader, load, null, true);
}
catch (err) {
load.er = err;
triggerOnload(loader, load, err);
triggerOnload(loader, load, err, true);
}

@@ -512,70 +519,5 @@ finally {

/*
* Import map support for SystemJS
*
* <script type="systemjs-importmap">{}</script>
* OR
* <script type="systemjs-importmap" src=package.json></script>
*
* Only those import maps available at the time of SystemJS initialization will be loaded
* and they will be loaded in DOM order.
*
* There is no support for dynamic import maps injection currently.
* Script instantiation loading
*/
var IMPORT_MAP = hasSymbol ? Symbol() : '#';
var IMPORT_MAP_PROMISE = hasSymbol ? Symbol() : '$';
iterateDocumentImportMaps(function (script) {
script._t = fetch(script.src).then(function (res) {
return res.text();
});
}, '[src]');
systemJSPrototype.prepareImport = function () {
var loader = this;
if (!loader[IMPORT_MAP_PROMISE]) {
loader[IMPORT_MAP] = { imports: {}, scopes: {} };
loader[IMPORT_MAP_PROMISE] = Promise.resolve();
iterateDocumentImportMaps(function (script) {
loader[IMPORT_MAP_PROMISE] = loader[IMPORT_MAP_PROMISE].then(function () {
return (script._t || script.src && fetch(script.src).then(function (res) { return res.text(); }) || Promise.resolve(script.innerHTML))
.then(function (text) {
try {
return JSON.parse(text);
} catch (err) {
throw Error( errMsg(1, "systemjs-importmap contains invalid JSON"));
}
})
.then(function (newMap) {
loader[IMPORT_MAP] = resolveAndComposeImportMap(newMap, script.src || baseUrl, loader[IMPORT_MAP]);
});
});
}, '');
}
return loader[IMPORT_MAP_PROMISE];
};
systemJSPrototype.resolve = function (id, parentUrl) {
parentUrl = parentUrl || !true || baseUrl;
return resolveImportMap(this[IMPORT_MAP], resolveIfNotPlainOrUrl(id, parentUrl) || id, parentUrl) || throwUnresolved(id, parentUrl);
};
function throwUnresolved (id, parentUrl) {
throw Error(errMsg(8, "Unable to resolve bare specifier '" + id + (parentUrl ? "' from " + parentUrl : "'")));
}
function iterateDocumentImportMaps(cb, extraSelector) {
if (hasDocument)
[].forEach.call(document.querySelectorAll('script[type="systemjs-importmap"]' + extraSelector), cb);
}
/*
* Supports loading System.register via script tag injection
*/
var systemRegister = systemJSPrototype.register;
systemJSPrototype.register = function (deps, declare) {
systemRegister.call(this, deps, declare);
};
systemJSPrototype.createScript = function (url) {

@@ -613,3 +555,3 @@ var script = document.createElement('script');

if (hasDocument) {
if (hasDocument)
window.addEventListener('error', function (evt) {

@@ -620,16 +562,123 @@ lastWindowErrorUrl = evt.filename;

window.addEventListener('DOMContentLoaded', loadScriptModules);
loadScriptModules();
systemJSPrototype.resolve = function (id, parentUrl) {
parentUrl = parentUrl || !true || baseUrl;
return resolveImportMap(this[IMPORT_MAP], resolveIfNotPlainOrUrl(id, parentUrl) || id, parentUrl) || throwUnresolved(id, parentUrl);
};
function throwUnresolved (id, parentUrl) {
throw Error(errMsg(8, "Unable to resolve bare specifier '" + id + (parentUrl ? "' from " + parentUrl : "'")));
}
/*
* SystemJS browser attachments for script and import map processing
*/
function loadScriptModules() {
[].forEach.call(
document.querySelectorAll('script[type=systemjs-module]'), function (script) {
if (script.src) {
System.import(script.src.slice(0, 7) === 'import:' ? script.src.slice(7) : resolveUrl(script.src, baseUrl));
}
});
var importMapPromise = Promise.resolve({ imports: {}, scopes: {}, depcache: {} });
// Scripts are processed immediately, on the first System.import, and on DOMReady.
// Import map scripts are processed only once (by being marked) and in order for each phase.
// This is to avoid using DOM mutation observers in core, although that would be an alternative.
var processFirst = hasDocument;
systemJSPrototype.prepareImport = function (doProcessScripts) {
if (processFirst || doProcessScripts) {
processScripts();
processFirst = false;
}
var loader = this;
return importMapPromise.then(function (importMap) {
loader[IMPORT_MAP] = importMap;
});
};
if (hasDocument) {
processScripts();
window.addEventListener('DOMContentLoaded', processScripts);
}
const systemInstantiate = systemJSPrototype.instantiate;
systemJSPrototype.instantiate = function (url, firstParentUrl) {
var preloads = this[IMPORT_MAP].depcache[url];
if (preloads) {
for (var i = 0; i < preloads.length; i++)
getOrCreateLoad(this, this.resolve(preloads[i], url), url);
}
return systemInstantiate.call(this, url, firstParentUrl);
};
function processScripts () {
[].forEach.call(document.querySelectorAll('script'), function (script) {
if (script.sp) // sp marker = systemjs processed
return;
// TODO: deprecate systemjs-module in next major now that we have auto import
if (script.type === 'systemjs-module') {
script.sp = true;
if (!script.src)
return;
System.import(script.src.slice(0, 7) === 'import:' ? script.src.slice(7) : resolveUrl(script.src, baseUrl));
}
else if (script.type === 'systemjs-importmap') {
script.sp = true;
importMapPromise = importMapPromise.then(function (importMap) {
if (script.src)
return fetch(script.src).then(function (res) {
return res.text();
}).then(function (text) {
return extendImportMap(importMap, text, script.src);
});
return extendImportMap(importMap, script.innerHTML, baseUrl);
});
}
});
}
function extendImportMap (importMap, newMapText, newMapUrl) {
try {
var newMap = JSON.parse(newMapText);
} catch (err) {
throw Error( errMsg(1, "systemjs-importmap contains invalid JSON"));
}
return resolveAndComposeImportMap(newMap, newMapUrl, importMap);
}
/**
* Auto-import <script src="system-module.js"></script> registrations
* Allows the browser preloader to work directly with SystemJS optimization
*/
var autoImports = {};
var systemRegister = systemJSPrototype.register;
systemJSPrototype.register = function (deps, declare) {
if (hasDocument && document.readyState === 'loading' && typeof deps !== 'string') {
var scripts = document.getElementsByTagName('script');
var lastScript = scripts[scripts.length - 1];
if (lastScript && lastScript.src) {
// Only import if not already in the registry.
// This avoids re-importing an inline dynamic System.import dependency.
// There is still a risk if a user dynamically injects a custom System.register script during DOM load that does an
// anomymous registration that is able to execute before DOM load completion, and thus is incorrectly matched to the
// last script when it wasn't causing a System.import of that last script, but this is deemed an acceptable edge case
// since due to custom user registration injection.
// Not using document.currentScript is done to ensure IE11 equivalence.
if (!this[REGISTRY][lastScript.src]) {
autoImports[lastScript.src] = [deps, declare];
// Auto import = immediately import the registration
// It is up to the user to manage execution order for deep preloading.
this.import(lastScript.src);
}
return;
}
}
return systemRegister.call(this, deps, declare);
};
var systemInstantiate$1 = systemJSPrototype.instantiate;
systemJSPrototype.instantiate = function (url) {
var autoImport = autoImports[url];
if (autoImport) {
delete autoImports[url];
return autoImport;
}
return systemInstantiate$1.apply(this, arguments);
};
/*

@@ -654,3 +703,3 @@ * Supports loading System.register in workers

(function (global) {
var systemJSPrototype = System.constructor.prototype;
var systemJSPrototype = global.System.constructor.prototype;

@@ -657,0 +706,0 @@ // safari unpredictably lists some new globals first or second in object order

/*
* SystemJS 6.3.3
* SystemJS 6.4.0
*/
!function(){function e(e,t){return(t||"")+" (SystemJS Error#"+e+" https://git.io/JvFET#"+e+")"}function t(e,t){if(-1!==e.indexOf("\\")&&(e=e.replace(/\\/g,"/")),"/"===e[0]&&"/"===e[1])return t.slice(0,t.indexOf(":")+1)+e;if("."===e[0]&&("/"===e[1]||"."===e[1]&&("/"===e[2]||2===e.length&&(e+="/"))||1===e.length&&(e+="/"))||"/"===e[0]){var n,r=t.slice(0,t.indexOf(":")+1);if(n="/"===t[r.length+1]?"file:"!==r?(n=t.slice(r.length+2)).slice(n.indexOf("/")+1):t.slice(8):t.slice(r.length+("/"===t[r.length])),"/"===e[0])return t.slice(0,t.length-n.length-1)+e;for(var i=n.slice(0,n.lastIndexOf("/")+1)+e,o=[],u=-1,c=0;i.length>c;c++)-1!==u?"/"===i[c]&&(o.push(i.slice(u,c+1)),u=-1):"."===i[c]?"."!==i[c+1]||"/"!==i[c+2]&&c+2!==i.length?"/"===i[c+1]||c+1===i.length?c+=1:u=c:(o.pop(),c+=2):u=c;return-1!==u&&o.push(i.slice(u)),t.slice(0,t.length-n.length)+o.join("")}}function n(e,n){return t(e,n)||(-1!==e.indexOf(":")?e:t("./"+e,n))}function r(e,t){for(var n in t)e[n]=t[n];return e}function i(e,n,r,i,o){for(var u in e){var f=t(u,r)||u,a=e[u];if("string"==typeof a){var l=s(i,t(a,r)||a,o);l?n[f]=l:c("W1",u,a,"bare specifier did not resolve")}}}function o(e,t){if(t[e])return e;var n=e.length;do{var r=e.slice(0,n+1);if(r in t)return r}while(-1!==(n=e.lastIndexOf("/",n-1)))}function u(e,t){var n=o(e,t);if(n){var r=t[n];if(null===r)return;if(n.length>=e.length||"/"===r[r.length-1])return r+e.slice(n.length);c("W2",n,r,"should have a trailing '/'")}}function c(t,n,r,i){console.warn(e(t,"Package target "+i+", resolving target '"+r+"' for "+n))}function s(e,t,n){for(var r=e.scopes,i=n&&o(n,r);i;){var c=u(t,r[i]);if(c)return c;i=o(i.slice(0,i.lastIndexOf("/")),r)}return u(t,e.imports)||-1!==t.indexOf(":")&&t}function f(){this[O]={}}function a(e){return e.id}function l(e,t,n){if(e.onload(n,t.id,t.d&&t.d.map(a)),n)throw n}function d(e,t){g&&[].forEach.call(document.querySelectorAll('script[type="systemjs-importmap"]'+t),e)}function h(){[].forEach.call(document.querySelectorAll("script[type=systemjs-module]"),(function(e){e.src&&System.import("import:"===e.src.slice(0,7)?e.src.slice(7):n(e.src,v))}))}var v,p="undefined"!=typeof Symbol,m="undefined"!=typeof self,g="undefined"!=typeof document,y=m?self:global;if(g){var b=document.querySelector("base[href]");b&&(v=b.href)}if(!v&&"undefined"!=typeof location){var S=(v=location.href.split("#")[0].split("?")[0]).lastIndexOf("/");-1!==S&&(v=v.slice(0,S+1))}var E,x=p&&Symbol.toStringTag,O=p?Symbol():"@",w=f.prototype;w.import=function(t,n){var r=this;return Promise.resolve(r.prepareImport()).then((function(){return r.resolve(t,n)})).then((function(t){var n=function t(n,r,i){var o=n[O][r];if(o)return o;var u=[],c=Object.create(null);x&&Object.defineProperty(c,x,{value:"Module"});var s=Promise.resolve().then((function(){return n.instantiate(r,i)})).then((function(t){if(!t)throw Error(e(2,"Module "+r+" did not instantiate"));var i=t[1]((function(e,t){o.h=!0;var n=!1;if("object"!=typeof e)e in c&&c[e]===t||(c[e]=t,n=!0);else{for(var r in e)t=e[r],r in c&&c[r]===t||(c[r]=t,n=!0);e.__esModule&&(c.__esModule=e.__esModule)}if(n)for(var i=0;u.length>i;i++){var s=u[i];s&&s(c)}return t}),2===t[1].length?{import:function(e){return n.import(e,r)},meta:n.createContext(r)}:void 0);return o.e=i.execute||function(){},[t[0],i.setters||[]]})),f=(s=s.catch((function(e){l(n,o,e)}))).then((function(e){return Promise.all(e[0].map((function(i,o){var u=e[1][o];return Promise.resolve(n.resolve(i,r)).then((function(e){var i=t(n,e,r);return Promise.resolve(i.I).then((function(){return u&&(i.i.push(u),!i.h&&i.I||u(i.n)),i}))}))}))).then((function(e){o.d=e}))}));return f.catch((function(e){o.e=null,o.er=e})),o=n[O][r]={id:r,i:u,n:c,I:s,L:f,h:!1,d:void 0,e:void 0,er:void 0,E:void 0,C:void 0}}(r,t);return n.C||function(e,t){return t.C=function e(t,n,r){if(!r[n.id])return r[n.id]=!0,Promise.resolve(n.L).then((function(){return Promise.all(n.d.map((function(n){return e(t,n,r)})))}))}(e,t,{}).then((function(){return function e(t,n,r){function i(){try{var e=n.e.call(j);if(e)return e=e.then((function(){n.C=n.n,n.E=null,l(t,n,null)}),(function(e){l(t,n,e)})),n.E=n.E||e;n.C=n.n,l(t,n,null)}catch(r){n.er=r,l(t,n,r)}finally{n.L=n.I=void 0,n.e=null}}if(!r[n.id]){if(r[n.id]=!0,!n.e){if(n.er)throw n.er;return n.E?n.E:void 0}var o;return n.d.forEach((function(i){try{(u=e(t,i,r))&&(u.catch((function(e){l(t,n,e)})),(o=o||[]).push(u))}catch(c){l(t,n,c)}var u})),o?Promise.all(o).then(i):i()}}(e,t,{})})).then((function(){return t.n}))}(r,n)}))},w.createContext=function(e){return{url:e}},w.onload=function(){},w.register=function(e,t){E=[e,t]},w.getRegister=function(){var e=E;return E=void 0,e};var j=Object.freeze(Object.create(null));y.System=new f;var P=p?Symbol():"#",C=p?Symbol():"$";d((function(e){e._t=fetch(e.src).then((function(e){return e.text()}))}),"[src]"),w.prepareImport=function(){var t=this;return t[C]||(t[P]={imports:{},scopes:{}},t[C]=Promise.resolve(),d((function(o){t[C]=t[C].then((function(){return(o._t||o.src&&fetch(o.src).then((function(e){return e.text()}))||Promise.resolve(o.innerHTML)).then((function(t){try{return JSON.parse(t)}catch(n){throw Error(e(1,"systemjs-importmap contains invalid JSON"))}})).then((function(e){t[P]=function(e,t,o){var u={imports:r({},o.imports),scopes:r({},o.scopes)};if(e.imports&&i(e.imports,u.imports,t,o,null),e.scopes)for(var c in e.scopes){var s=n(c,t);i(e.scopes[c],u.scopes[s]||(u.scopes[s]={}),t,o,s)}return u}(e,o.src||v,t[P])}))}))}),"")),t[C]},w.resolve=function(n,r){return s(this[P],t(n,r=r||v)||n,r)||function(t,n){throw Error(e(8,"Unable to resolve bare specifier '"+t+(n?"' from "+n:"'")))}(n,r)};var I,L,M=w.register;w.register=function(e,t){M.call(this,e,t)},w.createScript=function(e){var t=document.createElement("script");return t.charset="utf-8",t.async=!0,t.crossOrigin="anonymous",t.src=e,t},w.instantiate=function(t,n){var r=this;return new Promise((function(i,o){var u=w.createScript(t);u.addEventListener("error",(function(){o(Error(e(3,"Error loading "+t+(n?" from "+n:""))))})),u.addEventListener("load",(function(){document.head.removeChild(u),I===t?o(L):i(r.getRegister())})),document.head.appendChild(u)}))},g&&(window.addEventListener("error",(function(e){I=e.filename,L=e.error})),window.addEventListener("DOMContentLoaded",h),h()),m&&"function"==typeof importScripts&&(w.instantiate=function(e){var t=this;return Promise.resolve().then((function(){return importScripts(e),t.getRegister()}))}),function(e){function t(t){return!e.hasOwnProperty(t)||!isNaN(t)&&e.length>t||f&&e[t]&&"undefined"!=typeof window&&e[t].parent===window}var n,r,i,o=System.constructor.prototype,u=o.import;o.import=function(o,c){return function(){for(var o in n=r=void 0,e)t(o)||(n?r||(r=o):n=o,i=o)}(),u.call(this,o,c)};var c=[[],function(){return{}}],s=o.getRegister;o.getRegister=function(){var o=s.call(this);if(o)return o;var u,f=function(){var o,u=0;for(var c in e)if(!t(c)){if(0===u&&c!==n||1===u&&c!==r)return c;u++,o=c}if(o!==i)return o}();if(!f)return c;try{u=e[f]}catch(a){return c}return[[],function(e){return{execute:function(){e({default:u,__useDefault:!0})}}}]};var f="undefined"!=typeof navigator&&-1!==navigator.userAgent.indexOf("Trident")}("undefined"!=typeof self?self:global),function(t){var n=t.System.constructor.prototype,r=n.instantiate;n.shouldFetch=function(e){var t=e.split("?")[0].split("#")[0];return t.slice(t.lastIndexOf(".")).match(/\.(css|html|json|wasm)$/)},n.fetch=function(e){return fetch(e)},n.instantiate=function(t,n){var i=this;return this.shouldFetch(t)?this.fetch(t).then((function(r){if(!r.ok)throw Error(e(7,r.status+" "+r.statusText+", loading "+t+(n?" from "+n:"")));var o=r.headers.get("content-type");if(!o)throw Error(e(4,'Missing header "Content-Type", loading '+t+(n?" from "+n:"")));if(o.match(/^(text|application)\/(x-)?javascript(;|$)/))return r.text().then((function(e){return(0,eval)(e),i.getRegister()}));if(o.match(/^application\/json(;|$)/))return r.text().then((function(e){return[[],function(t){return{execute:function(){t("default",JSON.parse(e))}}}]}));if(o.match(/^text\/css(;|$)/))return r.text().then((function(e){return[[],function(t){return{execute:function(){var n=new CSSStyleSheet;n.replaceSync(e),t("default",n)}}}]}));if(o.match(/^application\/wasm(;|$)/))return(WebAssembly.compileStreaming?WebAssembly.compileStreaming(r):r.arrayBuffer().then(WebAssembly.compile)).then((function(e){var t=[],n=[],r={};return WebAssembly.Module.imports&&WebAssembly.Module.imports(e).forEach((function(e){var i=e.module;-1===t.indexOf(i)&&(t.push(i),n.push((function(e){r[i]=e})))})),[t,function(t){return{setters:n,execute:function(){return WebAssembly.instantiate(e,r).then((function(e){t(e.exports)}))}}}]}));throw Error(e(4,'Unknown module type "'+o+'"'))})):r.apply(this,arguments)}}("undefined"!=typeof self?self:global);var _="undefined"!=typeof Symbol&&Symbol.toStringTag;w.get=function(e){var t=this[O][e];if(t&&null===t.e&&!t.E)return t.er?null:t.n},w.set=function(t,n){try{new URL(t)}catch(u){console.warn(Error(e("W3",'"'+t+'" is not a valid URL to set in the module registry')))}var r;_&&"Module"===n[_]?r=n:(r=Object.assign(Object.create(null),n),_&&Object.defineProperty(r,_,{value:"Module"}));var i=Promise.resolve(r),o=this[O][t]||(this[O][t]={id:t,i:[],h:!1,d:[],e:null,er:void 0,E:void 0});return!o.e&&!o.E&&(Object.assign(o,{n:r,I:void 0,L:void 0,C:i}),r)},w.has=function(e){return!!this[O][e]},w.delete=function(e){var t=this[O],n=t[e];if(!n||null!==n.e||n.E)return!1;var r=n.i;return n.d&&n.d.forEach((function(e){var t=e.i.indexOf(n);-1!==t&&e.i.splice(t,1)})),delete t[e],function(){var n=t[e];if(!n||!r||null!==n.e||n.E)return!1;r.forEach((function(e){n.i.push(e),e(n.n)})),r=null}};var A="undefined"!=typeof Symbol&&Symbol.iterator;w.entries=function(){var e,t,n=this,r=Object.keys(n[O]),i=0,o={next:function(){for(;void 0!==(t=r[i++])&&void 0===(e=n.get(t)););return{done:void 0===t,value:void 0!==t&&[t,e]}}};return o[A]=function(){return this},o}}();
!function(){function e(e,t){return(t||"")+" (SystemJS Error#"+e+" https://git.io/JvFET#"+e+")"}function t(e,t){if(-1!==e.indexOf("\\")&&(e=e.replace(/\\/g,"/")),"/"===e[0]&&"/"===e[1])return t.slice(0,t.indexOf(":")+1)+e;if("."===e[0]&&("/"===e[1]||"."===e[1]&&("/"===e[2]||2===e.length&&(e+="/"))||1===e.length&&(e+="/"))||"/"===e[0]){var n,r=t.slice(0,t.indexOf(":")+1);if(n="/"===t[r.length+1]?"file:"!==r?(n=t.slice(r.length+2)).slice(n.indexOf("/")+1):t.slice(8):t.slice(r.length+("/"===t[r.length])),"/"===e[0])return t.slice(0,t.length-n.length-1)+e;for(var i=n.slice(0,n.lastIndexOf("/")+1)+e,o=[],u=-1,c=0;i.length>c;c++)-1!==u?"/"===i[c]&&(o.push(i.slice(u,c+1)),u=-1):"."===i[c]?"."!==i[c+1]||"/"!==i[c+2]&&c+2!==i.length?"/"===i[c+1]||c+1===i.length?c+=1:u=c:(o.pop(),c+=2):u=c;return-1!==u&&o.push(i.slice(u)),t.slice(0,t.length-n.length)+o.join("")}}function n(e,n){return t(e,n)||(-1!==e.indexOf(":")?e:t("./"+e,n))}function r(e,t){for(var n in t)e[n]=t[n];return e}function i(e,n,r,i,o){for(var u in e){var a=t(u,r)||u,f=e[u];if("string"==typeof f){var l=s(i,t(f,r)||f,o);l?n[a]=l:c("W1",u,f,"bare specifier did not resolve")}}}function o(e,t){if(t[e])return e;var n=e.length;do{var r=e.slice(0,n+1);if(r in t)return r}while(-1!==(n=e.lastIndexOf("/",n-1)))}function u(e,t){var n=o(e,t);if(n){var r=t[n];if(null===r)return;if(n.length>=e.length||"/"===r[r.length-1])return r+e.slice(n.length);c("W2",n,r,"should have a trailing '/'")}}function c(t,n,r,i){console.warn(e(t,"Package target "+i+", resolving target '"+r+"' for "+n))}function s(e,t,n){for(var r=e.scopes,i=n&&o(n,r);i;){var c=u(t,r[i]);if(c)return c;i=o(i.slice(0,i.lastIndexOf("/")),r)}return u(t,e.imports)||-1!==t.indexOf(":")&&t}function a(){this[j]={}}function f(e){return e.id}function l(e,t,n,r){if(e.onload(n,t.id,t.d&&t.d.map(f),!!r),n)throw n}function d(t,n,r){var i=t[j][n];if(i)return i;var o=[],u=Object.create(null);w&&Object.defineProperty(u,w,{value:"Module"});var c=Promise.resolve().then((function(){return t.instantiate(n,r)})).then((function(r){if(!r)throw Error(e(2,"Module "+n+" did not instantiate"));var c=r[1]((function(e,t){i.h=!0;var n=!1;if("object"!=typeof e)e in u&&u[e]===t||(u[e]=t,n=!0);else{for(var r in e)t=e[r],r in u&&u[r]===t||(u[r]=t,n=!0);e.__esModule&&(u.__esModule=e.__esModule)}if(n)for(var c=0;o.length>c;c++){var s=o[c];s&&s(u)}return t}),2===r[1].length?{import:function(e){return t.import(e,n)},meta:t.createContext(n)}:void 0);return i.e=c.execute||function(){},[r[0],c.setters||[]]})),s=(c=c.catch((function(e){l(t,i,e,!0)}))).then((function(e){return Promise.all(e[0].map((function(r,i){var o=e[1][i];return Promise.resolve(t.resolve(r,n)).then((function(e){var r=d(t,e,n);return Promise.resolve(r.I).then((function(){return o&&(r.i.push(o),!r.h&&r.I||o(r.n)),r}))}))}))).then((function(e){i.d=e}),(function(e){l(t,i,e,!1)}))}));return s.catch((function(e){i.e=null,i.er=e})),i=t[j][n]={id:n,i:o,n:u,I:c,L:s,h:!1,d:void 0,e:void 0,er:void 0,E:void 0,C:void 0}}function h(){[].forEach.call(document.querySelectorAll("script"),(function(e){if(!e.sp)if("systemjs-module"===e.type){if(e.sp=!0,!e.src)return;System.import("import:"===e.src.slice(0,7)?e.src.slice(7):n(e.src,v))}else"systemjs-importmap"===e.type&&(e.sp=!0,M=M.then((function(t){return e.src?fetch(e.src).then((function(e){return e.text()})).then((function(n){return p(t,n,e.src)})):p(t,e.innerHTML,v)})))}))}function p(t,o,u){try{var c=JSON.parse(o)}catch(s){throw Error(e(1,"systemjs-importmap contains invalid JSON"))}return function(e,t,o){var u={imports:r({},o.imports),scopes:r({},o.scopes),depcache:r({},o.depcache)};if(e.imports&&i(e.imports,u.imports,t,o,null),e.scopes)for(var c in e.scopes){var s=n(c,t);i(e.scopes[c],u.scopes[s]||(u.scopes[s]={}),t,o,s)}if(e.depcache)for(var a in e.depcache){var f=n(a,t);u.depcache[f]=e.depcache[a]}return u}(c,u,t)}var v,m="undefined"!=typeof Symbol,g="undefined"!=typeof self,y="undefined"!=typeof document,b=g?self:global;if(y){var E=document.querySelector("base[href]");E&&(v=E.href)}if(!v&&"undefined"!=typeof location){var S=(v=location.href.split("#")[0].split("?")[0]).lastIndexOf("/");-1!==S&&(v=v.slice(0,S+1))}var x,O=m?Symbol():"#",w=m&&Symbol.toStringTag,j=m?Symbol():"@",P=a.prototype;P.import=function(e,t){var n=this;return Promise.resolve(n.prepareImport()).then((function(){return n.resolve(e,t)})).then((function(e){var t=d(n,e);return t.C||function(e,t){return t.C=function e(t,n,r){if(!r[n.id])return r[n.id]=!0,Promise.resolve(n.L).then((function(){return Promise.all(n.d.map((function(n){return e(t,n,r)})))}))}(e,t,{}).then((function(){return function e(t,n,r){function i(){try{var e=n.e.call(L);if(e)return e=e.then((function(){n.C=n.n,n.E=null,l(t,n,null,!0)}),(function(e){n.er=e,n.E=null,l(t,n,e,!0)})),n.E=n.E||e;n.C=n.n,l(t,n,null,!0)}catch(r){n.er=r,l(t,n,r,!0)}finally{n.L=n.I=void 0,n.e=null}}if(!r[n.id]){if(r[n.id]=!0,!n.e){if(n.er)throw n.er;return n.E?n.E:void 0}var o;return n.d.forEach((function(i){try{var u=e(t,i,r);u&&(o=o||[]).push(u)}catch(c){n.e=null,n.er=c,l(t,n,c,!1)}})),o?Promise.all(o).then(i,(function(e){n.e=null,n.er=e,l(t,n,e,!1)})):i()}}(e,t,{})})).then((function(){return t.n}))}(n,t)}))},P.createContext=function(e){return{url:e}},P.onload=function(){},P.register=function(e,t){x=[e,t]},P.getRegister=function(){var e=x;return x=void 0,e};var C,I,L=Object.freeze(Object.create(null));b.System=new a,P.createScript=function(e){var t=document.createElement("script");return t.charset="utf-8",t.async=!0,t.crossOrigin="anonymous",t.src=e,t},P.instantiate=function(t,n){var r=this;return new Promise((function(i,o){var u=P.createScript(t);u.addEventListener("error",(function(){o(Error(e(3,"Error loading "+t+(n?" from "+n:""))))})),u.addEventListener("load",(function(){document.head.removeChild(u),C===t?o(I):i(r.getRegister())})),document.head.appendChild(u)}))},y&&window.addEventListener("error",(function(e){C=e.filename,I=e.error})),P.resolve=function(n,r){return s(this[O],t(n,r=r||v)||n,r)||function(t,n){throw Error(e(8,"Unable to resolve bare specifier '"+t+(n?"' from "+n:"'")))}(n,r)};var M=Promise.resolve({imports:{},scopes:{},depcache:{}}),W=y;P.prepareImport=function(e){(W||e)&&(h(),W=!1);var t=this;return M.then((function(e){t[O]=e}))},y&&(h(),window.addEventListener("DOMContentLoaded",h));const A=P.instantiate;P.instantiate=function(e,t){var n=this[O].depcache[e];if(n)for(var r=0;n.length>r;r++)d(this,this.resolve(n[r],e),e);return A.call(this,e,t)};var R={},T=P.register;P.register=function(e,t){if(y&&"loading"===document.readyState&&"string"!=typeof e){var n=document.getElementsByTagName("script"),r=n[n.length-1];if(r&&r.src)return void(this[j][r.src]||(R[r.src]=[e,t],this.import(r.src)))}return T.call(this,e,t)};var _=P.instantiate;P.instantiate=function(e){var t=R[e];return t?(delete R[e],t):_.apply(this,arguments)},g&&"function"==typeof importScripts&&(P.instantiate=function(e){var t=this;return Promise.resolve().then((function(){return importScripts(e),t.getRegister()}))}),function(e){function t(t){return!e.hasOwnProperty(t)||!isNaN(t)&&e.length>t||a&&e[t]&&"undefined"!=typeof window&&e[t].parent===window}var n,r,i,o=e.System.constructor.prototype,u=o.import;o.import=function(o,c){return function(){for(var o in n=r=void 0,e)t(o)||(n?r||(r=o):n=o,i=o)}(),u.call(this,o,c)};var c=[[],function(){return{}}],s=o.getRegister;o.getRegister=function(){var o=s.call(this);if(o)return o;var u,a=function(){var o,u=0;for(var c in e)if(!t(c)){if(0===u&&c!==n||1===u&&c!==r)return c;u++,o=c}if(o!==i)return o}();if(!a)return c;try{u=e[a]}catch(f){return c}return[[],function(e){return{execute:function(){e({default:u,__useDefault:!0})}}}]};var a="undefined"!=typeof navigator&&-1!==navigator.userAgent.indexOf("Trident")}("undefined"!=typeof self?self:global),function(t){var n=t.System.constructor.prototype,r=n.instantiate;n.shouldFetch=function(e){var t=e.split("?")[0].split("#")[0];return t.slice(t.lastIndexOf(".")).match(/\.(css|html|json|wasm)$/)},n.fetch=function(e){return fetch(e)},n.instantiate=function(t,n){var i=this;return this.shouldFetch(t)?this.fetch(t).then((function(r){if(!r.ok)throw Error(e(7,r.status+" "+r.statusText+", loading "+t+(n?" from "+n:"")));var o=r.headers.get("content-type");if(!o)throw Error(e(4,'Missing header "Content-Type", loading '+t+(n?" from "+n:"")));if(o.match(/^(text|application)\/(x-)?javascript(;|$)/))return r.text().then((function(e){return(0,eval)(e),i.getRegister()}));if(o.match(/^application\/json(;|$)/))return r.text().then((function(e){return[[],function(t){return{execute:function(){t("default",JSON.parse(e))}}}]}));if(o.match(/^text\/css(;|$)/))return r.text().then((function(e){return[[],function(t){return{execute:function(){var n=new CSSStyleSheet;n.replaceSync(e),t("default",n)}}}]}));if(o.match(/^application\/wasm(;|$)/))return(WebAssembly.compileStreaming?WebAssembly.compileStreaming(r):r.arrayBuffer().then(WebAssembly.compile)).then((function(e){var t=[],n=[],r={};return WebAssembly.Module.imports&&WebAssembly.Module.imports(e).forEach((function(e){var i=e.module;-1===t.indexOf(i)&&(t.push(i),n.push((function(e){r[i]=e})))})),[t,function(t){return{setters:n,execute:function(){return WebAssembly.instantiate(e,r).then((function(e){t(e.exports)}))}}}]}));throw Error(e(4,'Unknown module type "'+o+'"'))})):r.apply(this,arguments)}}("undefined"!=typeof self?self:global);var N="undefined"!=typeof Symbol&&Symbol.toStringTag;P.get=function(e){var t=this[j][e];if(t&&null===t.e&&!t.E)return t.er?null:t.n},P.set=function(t,n){try{new URL(t)}catch(u){console.warn(Error(e("W3",'"'+t+'" is not a valid URL to set in the module registry')))}var r;N&&"Module"===n[N]?r=n:(r=Object.assign(Object.create(null),n),N&&Object.defineProperty(r,N,{value:"Module"}));var i=Promise.resolve(r),o=this[j][t]||(this[j][t]={id:t,i:[],h:!1,d:[],e:null,er:void 0,E:void 0});return!o.e&&!o.E&&(Object.assign(o,{n:r,I:void 0,L:void 0,C:i}),r)},P.has=function(e){return!!this[j][e]},P.delete=function(e){var t=this[j],n=t[e];if(!n||null!==n.e||n.E)return!1;var r=n.i;return n.d&&n.d.forEach((function(e){var t=e.i.indexOf(n);-1!==t&&e.i.splice(t,1)})),delete t[e],function(){var n=t[e];if(!n||!r||null!==n.e||n.E)return!1;r.forEach((function(e){n.i.push(e),e(n.n)})),r=null}};var J="undefined"!=typeof Symbol&&Symbol.iterator;P.entries=function(){var e,t,n=this,r=Object.keys(n[j]),i=0,o={next:function(){for(;void 0!==(t=r[i++])&&void 0===(e=n.get(t)););return{done:void 0===t,value:void 0!==t&&[t,e]}}};return o[J]=function(){return this},o}}();
//# sourceMappingURL=system.min.js.map
{
"name": "systemjs",
"version": "6.3.3",
"version": "6.4.0",
"main": "dist/system-node.cjs",

@@ -5,0 +5,0 @@ "exports": {

@@ -81,2 +81,3 @@ # SystemJS

* [Transform loader](dist/extras/transform.js) support, using fetch and eval, supporting a hookable `loader.transform`
* [Dynamic import maps](dist/extras/dynamic-import-maps.js) support. This is currently a _potential_ new standard [feature](https://github.com/guybedford/import-maps-extensions#lazy-loading-of-import-maps).

@@ -83,0 +84,0 @@ The following extras are included in system.js loader by default, and can be added to the s.js loader for a smaller tailored footprint:

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc