mirror of
https://github.com/Tonejs/Tone.js
synced 2024-12-27 20:13:07 +00:00
1678 lines
No EOL
578 KiB
JavaScript
1678 lines
No EOL
578 KiB
JavaScript
(function webpackUniversalModuleDefinition(root, factory) {
|
|
if(typeof exports === 'object' && typeof module === 'object')
|
|
module.exports = factory(require("Tone"));
|
|
else if(typeof define === 'function' && define.amd)
|
|
define(["Tone"], factory);
|
|
else {
|
|
var a = typeof exports === 'object' ? factory(require("Tone")) : factory(root["Tone"]);
|
|
for(var i in a) (typeof exports === 'object' ? exports : root)[i] = a[i];
|
|
}
|
|
})(window, function(__WEBPACK_EXTERNAL_MODULE_tone__) {
|
|
return /******/ (function(modules) { // webpackBootstrap
|
|
/******/ // The module cache
|
|
/******/ var installedModules = {};
|
|
/******/
|
|
/******/ // The require function
|
|
/******/ function __webpack_require__(moduleId) {
|
|
/******/
|
|
/******/ // Check if module is in cache
|
|
/******/ if(installedModules[moduleId]) {
|
|
/******/ return installedModules[moduleId].exports;
|
|
/******/ }
|
|
/******/ // Create a new module (and put it into the cache)
|
|
/******/ var module = installedModules[moduleId] = {
|
|
/******/ i: moduleId,
|
|
/******/ l: false,
|
|
/******/ exports: {}
|
|
/******/ };
|
|
/******/
|
|
/******/ // Execute the module function
|
|
/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
|
|
/******/
|
|
/******/ // Flag the module as loaded
|
|
/******/ module.l = true;
|
|
/******/
|
|
/******/ // Return the exports of the module
|
|
/******/ return module.exports;
|
|
/******/ }
|
|
/******/
|
|
/******/
|
|
/******/ // expose the modules object (__webpack_modules__)
|
|
/******/ __webpack_require__.m = modules;
|
|
/******/
|
|
/******/ // expose the module cache
|
|
/******/ __webpack_require__.c = installedModules;
|
|
/******/
|
|
/******/ // define getter function for harmony exports
|
|
/******/ __webpack_require__.d = function(exports, name, getter) {
|
|
/******/ if(!__webpack_require__.o(exports, name)) {
|
|
/******/ Object.defineProperty(exports, name, { enumerable: true, get: getter });
|
|
/******/ }
|
|
/******/ };
|
|
/******/
|
|
/******/ // define __esModule on exports
|
|
/******/ __webpack_require__.r = function(exports) {
|
|
/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) {
|
|
/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
|
/******/ }
|
|
/******/ Object.defineProperty(exports, '__esModule', { value: true });
|
|
/******/ };
|
|
/******/
|
|
/******/ // create a fake namespace object
|
|
/******/ // mode & 1: value is a module id, require it
|
|
/******/ // mode & 2: merge all properties of value into the ns
|
|
/******/ // mode & 4: return value when already ns object
|
|
/******/ // mode & 8|1: behave like require
|
|
/******/ __webpack_require__.t = function(value, mode) {
|
|
/******/ if(mode & 1) value = __webpack_require__(value);
|
|
/******/ if(mode & 8) return value;
|
|
/******/ if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;
|
|
/******/ var ns = Object.create(null);
|
|
/******/ __webpack_require__.r(ns);
|
|
/******/ Object.defineProperty(ns, 'default', { enumerable: true, value: value });
|
|
/******/ if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));
|
|
/******/ return ns;
|
|
/******/ };
|
|
/******/
|
|
/******/ // getDefaultExport function for compatibility with non-harmony modules
|
|
/******/ __webpack_require__.n = function(module) {
|
|
/******/ var getter = module && module.__esModule ?
|
|
/******/ function getDefault() { return module['default']; } :
|
|
/******/ function getModuleExports() { return module; };
|
|
/******/ __webpack_require__.d(getter, 'a', getter);
|
|
/******/ return getter;
|
|
/******/ };
|
|
/******/
|
|
/******/ // Object.prototype.hasOwnProperty.call
|
|
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
|
/******/
|
|
/******/ // __webpack_public_path__
|
|
/******/ __webpack_require__.p = "";
|
|
/******/
|
|
/******/
|
|
/******/ // Load entry module and return exports
|
|
/******/ return __webpack_require__(__webpack_require__.s = "./src/gui/index.ts");
|
|
/******/ })
|
|
/************************************************************************/
|
|
/******/ ({
|
|
|
|
/***/ "./node_modules/@material/mwc-icon/mwc-icon-host-css.js":
|
|
/*!**************************************************************!*\
|
|
!*** ./node_modules/@material/mwc-icon/mwc-icon-host-css.js ***!
|
|
\**************************************************************/
|
|
/*! exports provided: style */
|
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"style\", function() { return style; });\n/* harmony import */ var lit_element__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! lit-element */ \"./node_modules/lit-element/lit-element.js\");\n/**\n@license\nCopyright 2018 Google Inc. All Rights Reserved.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n*/\n\nconst style = lit_element__WEBPACK_IMPORTED_MODULE_0__[\"css\"] `:host{font-family:var(--mdc-icon-font, \"Material Icons\");font-weight:normal;font-style:normal;font-size:var(--mdc-icon-size, 24px);line-height:1;letter-spacing:normal;text-transform:none;display:inline-block;white-space:nowrap;word-wrap:normal;direction:ltr;-webkit-font-smoothing:antialiased;text-rendering:optimizeLegibility;-moz-osx-font-smoothing:grayscale;font-feature-settings:\"liga\"}`;\n//# sourceMappingURL=mwc-icon-host-css.js.map\n\n//# sourceURL=webpack:///./node_modules/@material/mwc-icon/mwc-icon-host-css.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/@material/mwc-icon/mwc-icon.js":
|
|
/*!*****************************************************!*\
|
|
!*** ./node_modules/@material/mwc-icon/mwc-icon.js ***!
|
|
\*****************************************************/
|
|
/*! exports provided: Icon */
|
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"Icon\", function() { return Icon; });\n/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ \"./node_modules/tslib/tslib.es6.js\");\n/* harmony import */ var lit_element__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! lit-element */ \"./node_modules/lit-element/lit-element.js\");\n/* harmony import */ var _mwc_icon_host_css_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./mwc-icon-host-css.js */ \"./node_modules/@material/mwc-icon/mwc-icon-host-css.js\");\n\n/**\n@license\nCopyright 2018 Google Inc. All Rights Reserved.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n*/\n\n\n/** @soyCompatible */\nlet Icon = class Icon extends lit_element__WEBPACK_IMPORTED_MODULE_1__[\"LitElement\"] {\n /** @soyCompatible */\n render() {\n return lit_element__WEBPACK_IMPORTED_MODULE_1__[\"html\"] `<slot></slot>`;\n }\n};\nIcon.styles = _mwc_icon_host_css_js__WEBPACK_IMPORTED_MODULE_2__[\"style\"];\nIcon = Object(tslib__WEBPACK_IMPORTED_MODULE_0__[\"__decorate\"])([\n Object(lit_element__WEBPACK_IMPORTED_MODULE_1__[\"customElement\"])('mwc-icon')\n], Icon);\n\n//# sourceMappingURL=mwc-icon.js.map\n\n//# sourceURL=webpack:///./node_modules/@material/mwc-icon/mwc-icon.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/array-filter/index.js":
|
|
/*!********************************************!*\
|
|
!*** ./node_modules/array-filter/index.js ***!
|
|
\********************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports) {
|
|
|
|
eval("\n/**\n * Array#filter.\n *\n * @param {Array} arr\n * @param {Function} fn\n * @param {Object=} self\n * @return {Array}\n * @throw TypeError\n */\n\nmodule.exports = function (arr, fn, self) {\n if (arr.filter) return arr.filter(fn, self);\n if (void 0 === arr || null === arr) throw new TypeError;\n if ('function' != typeof fn) throw new TypeError;\n var ret = [];\n for (var i = 0; i < arr.length; i++) {\n if (!hasOwn.call(arr, i)) continue;\n var val = arr[i];\n if (fn.call(self, val, i, arr)) ret.push(val);\n }\n return ret;\n};\n\nvar hasOwn = Object.prototype.hasOwnProperty;\n\n\n//# sourceURL=webpack:///./node_modules/array-filter/index.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/audiokeys/src/AudioKeys.buffer.js":
|
|
/*!********************************************************!*\
|
|
!*** ./node_modules/audiokeys/src/AudioKeys.buffer.js ***!
|
|
\********************************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports) {
|
|
|
|
eval("// ================================================================\n// KEY BUFFER\n// ================================================================\n\n// The process is:\n\n// key press\n// add to self._state.keys\n// (an accurate representation of keys currently pressed)\n// resolve self.buffer\n// based on polyphony and priority, determine the notes\n// that get triggered for the user\n\nmodule.exports = {\n _addKey: function(e) {\n var self = this;\n // if the keyCode is one that can be mapped and isn't\n // already pressed, add it to the key object.\n if(self._isNote(e.keyCode) && !self._isPressed(e.keyCode)) {\n var newKey = self._makeNote(e.keyCode);\n // add the newKey to the list of keys\n self._state.keys = (self._state.keys || []).concat(newKey);\n // reevaluate the active notes based on our priority rules.\n // give it the new note to use if there is an event to trigger.\n self._update();\n } else if(self._isSpecialKey(e.keyCode)) {\n self._specialKey(e.keyCode);\n }\n },\n\n _removeKey: function(e) {\n var self = this;\n // if the keyCode is active, remove it from the key object.\n if(self._isPressed(e.keyCode)) {\n var keyToRemove;\n for(var i = 0; i < self._state.keys.length; i++) {\n if(self._state.keys[i].keyCode === e.keyCode) {\n keyToRemove = self._state.keys[i];\n break;\n }\n }\n\n // remove the key from _keys\n self._state.keys.splice(self._state.keys.indexOf(keyToRemove), 1);\n self._update();\n }\n },\n\n _isPressed: function(keyCode) {\n var self = this;\n\n if(!self._state.keys || !self._state.keys.length) {\n return false;\n }\n\n for(var i = 0; i < self._state.keys.length; i++) {\n if(self._state.keys[i].keyCode === keyCode) {\n return true;\n }\n }\n return false;\n },\n\n // turn a key object into a note object for the event listeners.\n _makeNote: function(keyCode) {\n var self = this;\n return {\n keyCode: keyCode,\n note: self._map(keyCode),\n frequency: self._toFrequency( self._map(keyCode) ),\n velocity: self._state.velocity\n };\n },\n\n // clear any active notes\n clear: function() {\n var self = this;\n // trigger note off for the notes in the buffer before\n // removing them.\n self._state.buffer.forEach( function(key) {\n // note up events should have a velocity of 0\n key.velocity = 0;\n self._trigger('up', key);\n });\n self._state.keys = [];\n self._state.buffer = [];\n },\n\n // ================================================================\n // NOTE BUFFER\n // ================================================================\n\n // every time a change is made to _keys due to a key on or key off\n // we need to call `_update`. It compares the `_keys` array to the\n // `buffer` array, which is the array of notes that are really\n // being played, makes the necessary changes to `buffer` and\n // triggers any events that need triggering.\n\n _update: function() {\n var self = this;\n\n // a key has been added to self._state.keys.\n // stash the old buffer\n var oldBuffer = self._state.buffer;\n // set the new priority in self.state._keys\n self._prioritize();\n // compare the buffers and trigger events based on\n // the differences.\n self._diff(oldBuffer);\n },\n\n _diff: function(oldBuffer) {\n var self = this;\n\n // if it's not in the OLD buffer, it's a note ON.\n // if it's not in the NEW buffer, it's a note OFF.\n\n var oldNotes = oldBuffer.map( function(key) {\n return key.keyCode;\n });\n\n var newNotes = self._state.buffer.map( function(key) {\n return key.keyCode;\n });\n\n // check for old (removed) notes\n var notesToRemove = [];\n oldNotes.forEach( function(key) {\n if(newNotes.indexOf(key) === -1) {\n notesToRemove.push(key);\n }\n });\n\n // check for new notes\n var notesToAdd = [];\n newNotes.forEach( function(key) {\n if(oldNotes.indexOf(key) === -1) {\n notesToAdd.push(key);\n }\n });\n\n notesToAdd.forEach( function(key) {\n for(var i = 0; i < self._state.buffer.length; i++) {\n if(self._state.buffer[i].keyCode === key) {\n self._trigger('down', self._state.buffer[i]);\n break;\n }\n }\n });\n\n notesToRemove.forEach( function(key) {\n // these need to fire the entire object\n for(var i = 0; i < oldBuffer.length; i++) {\n if(oldBuffer[i].keyCode === key) {\n // note up events should have a velocity of 0\n oldBuffer[i].velocity = 0;\n self._trigger('up', oldBuffer[i]);\n break;\n }\n }\n });\n },\n\n};\n\n\n\n//# sourceURL=webpack:///./node_modules/audiokeys/src/AudioKeys.buffer.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/audiokeys/src/AudioKeys.events.js":
|
|
/*!********************************************************!*\
|
|
!*** ./node_modules/audiokeys/src/AudioKeys.events.js ***!
|
|
\********************************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports) {
|
|
|
|
eval("// ================================================================\n// Event Listeners\n// ================================================================\n\n// AudioKeys has a very simple event handling system. Internally\n// we'll call self._trigger('down', argument) when we want to fire\n// an event for the user.\n\nmodule.exports = {\n down: function(fn) {\n var self = this;\n\n // add the function to our list of listeners\n self._listeners.down = (self._listeners.down || []).concat(fn);\n },\n\n up: function(fn) {\n var self = this;\n\n // add the function to our list of listeners\n self._listeners.up = (self._listeners.up || []).concat(fn);\n },\n\n _trigger: function(action /* args */) {\n var self = this;\n\n // if we have any listeners by this name ...\n if(self._listeners[action] && self._listeners[action].length) {\n // grab the arguments to pass to the listeners ...\n var args = Array.prototype.slice.call(arguments);\n args.splice(0, 1);\n // and call them!\n self._listeners[action].forEach( function(fn) {\n fn.apply(self, args);\n });\n }\n },\n\n // ================================================================\n // DOM Bindings\n // ================================================================\n\n _bind: function() {\n var self = this;\n\n if(typeof window !== 'undefined' && window.document) {\n window.document.addEventListener('keydown', function(e) {\n self._addKey(e);\n });\n window.document.addEventListener('keyup', function(e) {\n self._removeKey(e);\n });\n\n var lastFocus = true;\n setInterval( function() {\n if(window.document.hasFocus() === lastFocus) {\n return;\n }\n lastFocus = !lastFocus;\n if(!lastFocus) {\n self.clear();\n }\n }, 100);\n }\n },\n\n};\n\n\n//# sourceURL=webpack:///./node_modules/audiokeys/src/AudioKeys.events.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/audiokeys/src/AudioKeys.js":
|
|
/*!*************************************************!*\
|
|
!*** ./node_modules/audiokeys/src/AudioKeys.js ***!
|
|
\*************************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
eval("// Each file contains methods of the prototype.\n// We'll compose them all together here.\n\nvar state = __webpack_require__(/*! ./AudioKeys.state */ \"./node_modules/audiokeys/src/AudioKeys.state.js\");\nvar events = __webpack_require__(/*! ./AudioKeys.events */ \"./node_modules/audiokeys/src/AudioKeys.events.js\");\nvar mapping = __webpack_require__(/*! ./AudioKeys.mapping */ \"./node_modules/audiokeys/src/AudioKeys.mapping.js\");\nvar buffer = __webpack_require__(/*! ./AudioKeys.buffer */ \"./node_modules/audiokeys/src/AudioKeys.buffer.js\");\nvar priority = __webpack_require__(/*! ./AudioKeys.priority */ \"./node_modules/audiokeys/src/AudioKeys.priority.js\");\nvar special = __webpack_require__(/*! ./AudioKeys.special */ \"./node_modules/audiokeys/src/AudioKeys.special.js\");\n\nfunction AudioKeys(options) {\n var self = this;\n\n self._setState(options);\n\n // all listeners are stored in arrays in their respective properties.\n // e.g. self._listeners.down = [fn1, fn2, ... ]\n self._listeners = {};\n\n // bind DOM events\n self._bind();\n}\n\n// state\nAudioKeys.prototype._setState = state._setState;\nAudioKeys.prototype._extendState = state._extendState;\nAudioKeys.prototype.set = state.set;\nAudioKeys.prototype.get = state.get;\n\n// events\nAudioKeys.prototype.down = events.down;\nAudioKeys.prototype.up = events.up;\nAudioKeys.prototype._trigger = events._trigger;\nAudioKeys.prototype._bind = events._bind;\n\n// mapping\nAudioKeys.prototype._map = mapping._map;\nAudioKeys.prototype._offset = mapping._offset;\nAudioKeys.prototype._isNote = mapping._isNote;\nAudioKeys.prototype._toFrequency = mapping._toFrequency;\nAudioKeys.prototype._keyMap = mapping._keyMap;\n\n// buffer\nAudioKeys.prototype._addKey = buffer._addKey;\nAudioKeys.prototype._removeKey = buffer._removeKey;\nAudioKeys.prototype._isPressed = buffer._isPressed;\nAudioKeys.prototype._makeNote = buffer._makeNote;\nAudioKeys.prototype.clear = buffer.clear;\nAudioKeys.prototype._update = buffer._update;\nAudioKeys.prototype._diff = buffer._diff;\n\n// priority\nAudioKeys.prototype._prioritize = priority._prioritize;\nAudioKeys.prototype._last = priority._last;\nAudioKeys.prototype._first = priority._first;\nAudioKeys.prototype._highest = priority._highest;\nAudioKeys.prototype._lowest = priority._lowest;\n\n// special\nAudioKeys.prototype._isSpecialKey = special._isSpecialKey;\nAudioKeys.prototype._specialKey = special._specialKey;\nAudioKeys.prototype._specialKeyMap = special._specialKeyMap;\n\n// Browserify will take care of making this a global\n// in a browser environment without a build system.\nmodule.exports = AudioKeys;\n\n//# sourceURL=webpack:///./node_modules/audiokeys/src/AudioKeys.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/audiokeys/src/AudioKeys.mapping.js":
|
|
/*!*********************************************************!*\
|
|
!*** ./node_modules/audiokeys/src/AudioKeys.mapping.js ***!
|
|
\*********************************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports) {
|
|
|
|
eval("module.exports = {\n // _map returns the midi note for a given keyCode.\n _map: function(keyCode) {\n return this._keyMap[this._state.rows][keyCode] + this._offset();\n },\n\n _offset: function() {\n return this._state.rootNote - this._keyMap[this._state.rows].root + (this._state.octave * 12);\n },\n\n // _isNote determines whether a keyCode is a note or not.\n _isNote: function(keyCode) {\n return !!this._keyMap[this._state.rows][keyCode];\n },\n\n // convert a midi note to a frequency. we assume here that _map has\n // already been called (to account for a potential rootNote offset)\n _toFrequency: function(note) {\n return ( Math.pow(2, ( note-69 ) / 12) ) * 440.0;\n },\n\n // the object keys correspond to `rows`, so `_keyMap[rows]` should\n // retrieve that particular mapping.\n _keyMap: {\n 1: {\n root: 60,\n // starting with the 'a' key\n 65: 60,\n 87: 61,\n 83: 62,\n 69: 63,\n 68: 64,\n 70: 65,\n 84: 66,\n 71: 67,\n 89: 68,\n 72: 69,\n 85: 70,\n 74: 71,\n 75: 72,\n 79: 73,\n 76: 74,\n 80: 75,\n 186: 76,\n 222: 77\n },\n 2: {\n root: 60,\n // bottom row\n 90: 60,\n 83: 61,\n 88: 62,\n 68: 63,\n 67: 64,\n 86: 65,\n 71: 66,\n 66: 67,\n 72: 68,\n 78: 69,\n 74: 70,\n 77: 71,\n 188: 72,\n 76: 73,\n 190: 74,\n 186: 75,\n 191: 76,\n // top row\n 81: 72,\n 50: 73,\n 87: 74,\n 51: 75,\n 69: 76,\n 82: 77,\n 53: 78,\n 84: 79,\n 54: 80,\n 89: 81,\n 55: 82,\n 85: 83,\n 73: 84,\n 57: 85,\n 79: 86,\n 48: 87,\n 80: 88,\n 219: 89,\n 187: 90,\n 221: 91\n }\n },\n\n};\n\n\n\n//# sourceURL=webpack:///./node_modules/audiokeys/src/AudioKeys.mapping.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/audiokeys/src/AudioKeys.priority.js":
|
|
/*!**********************************************************!*\
|
|
!*** ./node_modules/audiokeys/src/AudioKeys.priority.js ***!
|
|
\**********************************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports) {
|
|
|
|
eval("module.exports = {\n _prioritize: function() {\n var self = this;\n\n // if all the keys have been turned off, no need\n // to do anything here.\n if(!self._state.keys.length) {\n self._state.buffer = [];\n return;\n }\n\n\n if(self._state.polyphony >= self._state.keys.length) {\n // every note is active\n self._state.keys = self._state.keys.map( function(key) {\n key.isActive = true;\n return key;\n });\n } else {\n // set all keys to inactive.\n self._state.keys = self._state.keys.map( function(key) {\n key.isActive = false;\n return key;\n });\n\n self['_' + self._state.priority]();\n }\n\n // now take the isActive keys and set the new buffer.\n self._state.buffer = [];\n\n self._state.keys.forEach( function(key) {\n if(key.isActive) {\n self._state.buffer.push(key);\n }\n });\n\n // done.\n },\n\n _last: function() {\n var self = this;\n // set the last bunch to active based on the polyphony.\n for(var i = self._state.keys.length - self._state.polyphony; i < self._state.keys.length; i++) {\n self._state.keys[i].isActive = true;\n }\n },\n\n _first: function() {\n var self = this;\n // set the last bunch to active based on the polyphony.\n for(var i = 0; i < self._state.polyphony; i++) {\n self._state.keys[i].isActive = true;\n }\n },\n\n _highest: function() {\n var self = this;\n // get the highest notes and set them to active\n var notes = self._state.keys.map( function(key) {\n return key.note;\n });\n\n notes.sort( function(b,a) {\n if(a === b) {\n return 0;\n }\n return a < b ? -1 : 1;\n });\n\n notes.splice(self._state.polyphony, Number.MAX_VALUE);\n\n self._state.keys.forEach( function(key) {\n if(notes.indexOf(key.note) !== -1) {\n key.isActive = true;\n }\n });\n },\n\n _lowest: function() {\n var self = this;\n // get the lowest notes and set them to active\n var notes = self._state.keys.map( function(key) {\n return key.note;\n });\n\n notes.sort( function(a,b) {\n if(a === b) {\n return 0;\n }\n return a < b ? -1 : 1;\n });\n\n notes.splice(self._state.polyphony, Number.MAX_VALUE);\n\n self._state.keys.forEach( function(key) {\n if(notes.indexOf(key.note) !== -1) {\n key.isActive = true;\n }\n });\n },\n\n};\n\n\n//# sourceURL=webpack:///./node_modules/audiokeys/src/AudioKeys.priority.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/audiokeys/src/AudioKeys.special.js":
|
|
/*!*********************************************************!*\
|
|
!*** ./node_modules/audiokeys/src/AudioKeys.special.js ***!
|
|
\*********************************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports) {
|
|
|
|
eval("// This file maps special keys to the state— octave shifting and\n// velocity selection, both available when `rows` = 1.\nmodule.exports = {\n _isSpecialKey: function(keyCode) {\n return (this._state.rows === 1 && this._specialKeyMap[keyCode]);\n },\n\n _specialKey: function(keyCode) {\n var self = this;\n if(self._specialKeyMap[keyCode].type === 'octave' && self._state.octaveControls) {\n // shift the state of the `octave`\n self._state.octave += self._specialKeyMap[keyCode].value;\n } else if(self._specialKeyMap[keyCode].type === 'velocity' && self._state.velocityControls) {\n // set the `velocity` to a new value\n self._state.velocity = self._specialKeyMap[keyCode].value;\n }\n },\n\n _specialKeyMap: {\n // octaves\n 90: {\n type: 'octave',\n value: -1\n },\n 88: {\n type: 'octave',\n value: 1\n },\n // velocity\n 49: {\n type: 'velocity',\n value: 1\n },\n 50: {\n type: 'velocity',\n value: 14\n },\n 51: {\n type: 'velocity',\n value: 28\n },\n 52: {\n type: 'velocity',\n value: 42\n },\n 53: {\n type: 'velocity',\n value: 56\n },\n 54: {\n type: 'velocity',\n value: 70\n },\n 55: {\n type: 'velocity',\n value: 84\n },\n 56: {\n type: 'velocity',\n value: 98\n },\n 57: {\n type: 'velocity',\n value: 112\n },\n 48: {\n type: 'velocity',\n value: 127\n },\n },\n\n};\n\n\n//# sourceURL=webpack:///./node_modules/audiokeys/src/AudioKeys.special.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/audiokeys/src/AudioKeys.state.js":
|
|
/*!*******************************************************!*\
|
|
!*** ./node_modules/audiokeys/src/AudioKeys.state.js ***!
|
|
\*******************************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports) {
|
|
|
|
eval("module.exports = {\n _setState: function(options) {\n var self = this;\n\n if(!options) {\n options = {};\n }\n\n // the state is kept in this object\n self._state = {};\n\n // set some defaults ...\n self._extendState({\n polyphony: 4,\n rows: 1,\n priority: 'last',\n rootNote: 60,\n octaveControls: true,\n octave: 0,\n velocityControls: true,\n velocity: 127,\n keys: [],\n buffer: []\n });\n\n // ... and override them with options.\n self._extendState(options);\n },\n\n _extendState: function(options) {\n var self = this;\n\n for(var o in options) {\n self._state[o] = options[o];\n }\n },\n\n set: function(/* options || property, value */) {\n var self = this;\n\n if(arguments.length === 1) {\n self._extendState(arguments[0]);\n } else {\n self._state[arguments[0]] = arguments[1];\n }\n\n return this;\n },\n\n get: function(property) {\n var self = this;\n\n return self._state[property];\n },\n\n};\n\n\n//# sourceURL=webpack:///./node_modules/audiokeys/src/AudioKeys.state.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/available-typed-arrays/index.js":
|
|
/*!******************************************************!*\
|
|
!*** ./node_modules/available-typed-arrays/index.js ***!
|
|
\******************************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("/* WEBPACK VAR INJECTION */(function(global) {\n\nvar filter = __webpack_require__(/*! array-filter */ \"./node_modules/array-filter/index.js\");\n\nmodule.exports = function availableTypedArrays() {\n\treturn filter([\n\t\t'BigInt64Array',\n\t\t'BigUint64Array',\n\t\t'Float32Array',\n\t\t'Float64Array',\n\t\t'Int16Array',\n\t\t'Int32Array',\n\t\t'Int8Array',\n\t\t'Uint16Array',\n\t\t'Uint32Array',\n\t\t'Uint8Array',\n\t\t'Uint8ClampedArray'\n\t], function (typedArray) {\n\t\treturn typeof global[typedArray] === 'function';\n\t});\n};\n\n/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./../webpack/buildin/global.js */ \"./node_modules/webpack/buildin/global.js\")))\n\n//# sourceURL=webpack:///./node_modules/available-typed-arrays/index.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/color-convert/conversions.js":
|
|
/*!***************************************************!*\
|
|
!*** ./node_modules/color-convert/conversions.js ***!
|
|
\***************************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
eval("/* MIT license */\nvar cssKeywords = __webpack_require__(/*! color-name */ \"./node_modules/color-name/index.js\");\n\n// NOTE: conversions should only return primitive values (i.e. arrays, or\n// values that give correct `typeof` results).\n// do not use box values types (i.e. Number(), String(), etc.)\n\nvar reverseKeywords = {};\nfor (var key in cssKeywords) {\n\tif (cssKeywords.hasOwnProperty(key)) {\n\t\treverseKeywords[cssKeywords[key]] = key;\n\t}\n}\n\nvar convert = module.exports = {\n\trgb: {channels: 3, labels: 'rgb'},\n\thsl: {channels: 3, labels: 'hsl'},\n\thsv: {channels: 3, labels: 'hsv'},\n\thwb: {channels: 3, labels: 'hwb'},\n\tcmyk: {channels: 4, labels: 'cmyk'},\n\txyz: {channels: 3, labels: 'xyz'},\n\tlab: {channels: 3, labels: 'lab'},\n\tlch: {channels: 3, labels: 'lch'},\n\thex: {channels: 1, labels: ['hex']},\n\tkeyword: {channels: 1, labels: ['keyword']},\n\tansi16: {channels: 1, labels: ['ansi16']},\n\tansi256: {channels: 1, labels: ['ansi256']},\n\thcg: {channels: 3, labels: ['h', 'c', 'g']},\n\tapple: {channels: 3, labels: ['r16', 'g16', 'b16']},\n\tgray: {channels: 1, labels: ['gray']}\n};\n\n// hide .channels and .labels properties\nfor (var model in convert) {\n\tif (convert.hasOwnProperty(model)) {\n\t\tif (!('channels' in convert[model])) {\n\t\t\tthrow new Error('missing channels property: ' + model);\n\t\t}\n\n\t\tif (!('labels' in convert[model])) {\n\t\t\tthrow new Error('missing channel labels property: ' + model);\n\t\t}\n\n\t\tif (convert[model].labels.length !== convert[model].channels) {\n\t\t\tthrow new Error('channel and label counts mismatch: ' + model);\n\t\t}\n\n\t\tvar channels = convert[model].channels;\n\t\tvar labels = convert[model].labels;\n\t\tdelete convert[model].channels;\n\t\tdelete convert[model].labels;\n\t\tObject.defineProperty(convert[model], 'channels', {value: channels});\n\t\tObject.defineProperty(convert[model], 'labels', {value: labels});\n\t}\n}\n\nconvert.rgb.hsl = function (rgb) {\n\tvar r = rgb[0] / 255;\n\tvar g = rgb[1] / 255;\n\tvar b = rgb[2] / 255;\n\tvar min = Math.min(r, g, b);\n\tvar max = Math.max(r, g, b);\n\tvar delta = max - min;\n\tvar h;\n\tvar s;\n\tvar l;\n\n\tif (max === min) {\n\t\th = 0;\n\t} else if (r === max) {\n\t\th = (g - b) / delta;\n\t} else if (g === max) {\n\t\th = 2 + (b - r) / delta;\n\t} else if (b === max) {\n\t\th = 4 + (r - g) / delta;\n\t}\n\n\th = Math.min(h * 60, 360);\n\n\tif (h < 0) {\n\t\th += 360;\n\t}\n\n\tl = (min + max) / 2;\n\n\tif (max === min) {\n\t\ts = 0;\n\t} else if (l <= 0.5) {\n\t\ts = delta / (max + min);\n\t} else {\n\t\ts = delta / (2 - max - min);\n\t}\n\n\treturn [h, s * 100, l * 100];\n};\n\nconvert.rgb.hsv = function (rgb) {\n\tvar rdif;\n\tvar gdif;\n\tvar bdif;\n\tvar h;\n\tvar s;\n\n\tvar r = rgb[0] / 255;\n\tvar g = rgb[1] / 255;\n\tvar b = rgb[2] / 255;\n\tvar v = Math.max(r, g, b);\n\tvar diff = v - Math.min(r, g, b);\n\tvar diffc = function (c) {\n\t\treturn (v - c) / 6 / diff + 1 / 2;\n\t};\n\n\tif (diff === 0) {\n\t\th = s = 0;\n\t} else {\n\t\ts = diff / v;\n\t\trdif = diffc(r);\n\t\tgdif = diffc(g);\n\t\tbdif = diffc(b);\n\n\t\tif (r === v) {\n\t\t\th = bdif - gdif;\n\t\t} else if (g === v) {\n\t\t\th = (1 / 3) + rdif - bdif;\n\t\t} else if (b === v) {\n\t\t\th = (2 / 3) + gdif - rdif;\n\t\t}\n\t\tif (h < 0) {\n\t\t\th += 1;\n\t\t} else if (h > 1) {\n\t\t\th -= 1;\n\t\t}\n\t}\n\n\treturn [\n\t\th * 360,\n\t\ts * 100,\n\t\tv * 100\n\t];\n};\n\nconvert.rgb.hwb = function (rgb) {\n\tvar r = rgb[0];\n\tvar g = rgb[1];\n\tvar b = rgb[2];\n\tvar h = convert.rgb.hsl(rgb)[0];\n\tvar w = 1 / 255 * Math.min(r, Math.min(g, b));\n\n\tb = 1 - 1 / 255 * Math.max(r, Math.max(g, b));\n\n\treturn [h, w * 100, b * 100];\n};\n\nconvert.rgb.cmyk = function (rgb) {\n\tvar r = rgb[0] / 255;\n\tvar g = rgb[1] / 255;\n\tvar b = rgb[2] / 255;\n\tvar c;\n\tvar m;\n\tvar y;\n\tvar k;\n\n\tk = Math.min(1 - r, 1 - g, 1 - b);\n\tc = (1 - r - k) / (1 - k) || 0;\n\tm = (1 - g - k) / (1 - k) || 0;\n\ty = (1 - b - k) / (1 - k) || 0;\n\n\treturn [c * 100, m * 100, y * 100, k * 100];\n};\n\n/**\n * See https://en.m.wikipedia.org/wiki/Euclidean_distance#Squared_Euclidean_distance\n * */\nfunction comparativeDistance(x, y) {\n\treturn (\n\t\tMath.pow(x[0] - y[0], 2) +\n\t\tMath.pow(x[1] - y[1], 2) +\n\t\tMath.pow(x[2] - y[2], 2)\n\t);\n}\n\nconvert.rgb.keyword = function (rgb) {\n\tvar reversed = reverseKeywords[rgb];\n\tif (reversed) {\n\t\treturn reversed;\n\t}\n\n\tvar currentClosestDistance = Infinity;\n\tvar currentClosestKeyword;\n\n\tfor (var keyword in cssKeywords) {\n\t\tif (cssKeywords.hasOwnProperty(keyword)) {\n\t\t\tvar value = cssKeywords[keyword];\n\n\t\t\t// Compute comparative distance\n\t\t\tvar distance = comparativeDistance(rgb, value);\n\n\t\t\t// Check if its less, if so set as closest\n\t\t\tif (distance < currentClosestDistance) {\n\t\t\t\tcurrentClosestDistance = distance;\n\t\t\t\tcurrentClosestKeyword = keyword;\n\t\t\t}\n\t\t}\n\t}\n\n\treturn currentClosestKeyword;\n};\n\nconvert.keyword.rgb = function (keyword) {\n\treturn cssKeywords[keyword];\n};\n\nconvert.rgb.xyz = function (rgb) {\n\tvar r = rgb[0] / 255;\n\tvar g = rgb[1] / 255;\n\tvar b = rgb[2] / 255;\n\n\t// assume sRGB\n\tr = r > 0.04045 ? Math.pow(((r + 0.055) / 1.055), 2.4) : (r / 12.92);\n\tg = g > 0.04045 ? Math.pow(((g + 0.055) / 1.055), 2.4) : (g / 12.92);\n\tb = b > 0.04045 ? Math.pow(((b + 0.055) / 1.055), 2.4) : (b / 12.92);\n\n\tvar x = (r * 0.4124) + (g * 0.3576) + (b * 0.1805);\n\tvar y = (r * 0.2126) + (g * 0.7152) + (b * 0.0722);\n\tvar z = (r * 0.0193) + (g * 0.1192) + (b * 0.9505);\n\n\treturn [x * 100, y * 100, z * 100];\n};\n\nconvert.rgb.lab = function (rgb) {\n\tvar xyz = convert.rgb.xyz(rgb);\n\tvar x = xyz[0];\n\tvar y = xyz[1];\n\tvar z = xyz[2];\n\tvar l;\n\tvar a;\n\tvar b;\n\n\tx /= 95.047;\n\ty /= 100;\n\tz /= 108.883;\n\n\tx = x > 0.008856 ? Math.pow(x, 1 / 3) : (7.787 * x) + (16 / 116);\n\ty = y > 0.008856 ? Math.pow(y, 1 / 3) : (7.787 * y) + (16 / 116);\n\tz = z > 0.008856 ? Math.pow(z, 1 / 3) : (7.787 * z) + (16 / 116);\n\n\tl = (116 * y) - 16;\n\ta = 500 * (x - y);\n\tb = 200 * (y - z);\n\n\treturn [l, a, b];\n};\n\nconvert.hsl.rgb = function (hsl) {\n\tvar h = hsl[0] / 360;\n\tvar s = hsl[1] / 100;\n\tvar l = hsl[2] / 100;\n\tvar t1;\n\tvar t2;\n\tvar t3;\n\tvar rgb;\n\tvar val;\n\n\tif (s === 0) {\n\t\tval = l * 255;\n\t\treturn [val, val, val];\n\t}\n\n\tif (l < 0.5) {\n\t\tt2 = l * (1 + s);\n\t} else {\n\t\tt2 = l + s - l * s;\n\t}\n\n\tt1 = 2 * l - t2;\n\n\trgb = [0, 0, 0];\n\tfor (var i = 0; i < 3; i++) {\n\t\tt3 = h + 1 / 3 * -(i - 1);\n\t\tif (t3 < 0) {\n\t\t\tt3++;\n\t\t}\n\t\tif (t3 > 1) {\n\t\t\tt3--;\n\t\t}\n\n\t\tif (6 * t3 < 1) {\n\t\t\tval = t1 + (t2 - t1) * 6 * t3;\n\t\t} else if (2 * t3 < 1) {\n\t\t\tval = t2;\n\t\t} else if (3 * t3 < 2) {\n\t\t\tval = t1 + (t2 - t1) * (2 / 3 - t3) * 6;\n\t\t} else {\n\t\t\tval = t1;\n\t\t}\n\n\t\trgb[i] = val * 255;\n\t}\n\n\treturn rgb;\n};\n\nconvert.hsl.hsv = function (hsl) {\n\tvar h = hsl[0];\n\tvar s = hsl[1] / 100;\n\tvar l = hsl[2] / 100;\n\tvar smin = s;\n\tvar lmin = Math.max(l, 0.01);\n\tvar sv;\n\tvar v;\n\n\tl *= 2;\n\ts *= (l <= 1) ? l : 2 - l;\n\tsmin *= lmin <= 1 ? lmin : 2 - lmin;\n\tv = (l + s) / 2;\n\tsv = l === 0 ? (2 * smin) / (lmin + smin) : (2 * s) / (l + s);\n\n\treturn [h, sv * 100, v * 100];\n};\n\nconvert.hsv.rgb = function (hsv) {\n\tvar h = hsv[0] / 60;\n\tvar s = hsv[1] / 100;\n\tvar v = hsv[2] / 100;\n\tvar hi = Math.floor(h) % 6;\n\n\tvar f = h - Math.floor(h);\n\tvar p = 255 * v * (1 - s);\n\tvar q = 255 * v * (1 - (s * f));\n\tvar t = 255 * v * (1 - (s * (1 - f)));\n\tv *= 255;\n\n\tswitch (hi) {\n\t\tcase 0:\n\t\t\treturn [v, t, p];\n\t\tcase 1:\n\t\t\treturn [q, v, p];\n\t\tcase 2:\n\t\t\treturn [p, v, t];\n\t\tcase 3:\n\t\t\treturn [p, q, v];\n\t\tcase 4:\n\t\t\treturn [t, p, v];\n\t\tcase 5:\n\t\t\treturn [v, p, q];\n\t}\n};\n\nconvert.hsv.hsl = function (hsv) {\n\tvar h = hsv[0];\n\tvar s = hsv[1] / 100;\n\tvar v = hsv[2] / 100;\n\tvar vmin = Math.max(v, 0.01);\n\tvar lmin;\n\tvar sl;\n\tvar l;\n\n\tl = (2 - s) * v;\n\tlmin = (2 - s) * vmin;\n\tsl = s * vmin;\n\tsl /= (lmin <= 1) ? lmin : 2 - lmin;\n\tsl = sl || 0;\n\tl /= 2;\n\n\treturn [h, sl * 100, l * 100];\n};\n\n// http://dev.w3.org/csswg/css-color/#hwb-to-rgb\nconvert.hwb.rgb = function (hwb) {\n\tvar h = hwb[0] / 360;\n\tvar wh = hwb[1] / 100;\n\tvar bl = hwb[2] / 100;\n\tvar ratio = wh + bl;\n\tvar i;\n\tvar v;\n\tvar f;\n\tvar n;\n\n\t// wh + bl cant be > 1\n\tif (ratio > 1) {\n\t\twh /= ratio;\n\t\tbl /= ratio;\n\t}\n\n\ti = Math.floor(6 * h);\n\tv = 1 - bl;\n\tf = 6 * h - i;\n\n\tif ((i & 0x01) !== 0) {\n\t\tf = 1 - f;\n\t}\n\n\tn = wh + f * (v - wh); // linear interpolation\n\n\tvar r;\n\tvar g;\n\tvar b;\n\tswitch (i) {\n\t\tdefault:\n\t\tcase 6:\n\t\tcase 0: r = v; g = n; b = wh; break;\n\t\tcase 1: r = n; g = v; b = wh; break;\n\t\tcase 2: r = wh; g = v; b = n; break;\n\t\tcase 3: r = wh; g = n; b = v; break;\n\t\tcase 4: r = n; g = wh; b = v; break;\n\t\tcase 5: r = v; g = wh; b = n; break;\n\t}\n\n\treturn [r * 255, g * 255, b * 255];\n};\n\nconvert.cmyk.rgb = function (cmyk) {\n\tvar c = cmyk[0] / 100;\n\tvar m = cmyk[1] / 100;\n\tvar y = cmyk[2] / 100;\n\tvar k = cmyk[3] / 100;\n\tvar r;\n\tvar g;\n\tvar b;\n\n\tr = 1 - Math.min(1, c * (1 - k) + k);\n\tg = 1 - Math.min(1, m * (1 - k) + k);\n\tb = 1 - Math.min(1, y * (1 - k) + k);\n\n\treturn [r * 255, g * 255, b * 255];\n};\n\nconvert.xyz.rgb = function (xyz) {\n\tvar x = xyz[0] / 100;\n\tvar y = xyz[1] / 100;\n\tvar z = xyz[2] / 100;\n\tvar r;\n\tvar g;\n\tvar b;\n\n\tr = (x * 3.2406) + (y * -1.5372) + (z * -0.4986);\n\tg = (x * -0.9689) + (y * 1.8758) + (z * 0.0415);\n\tb = (x * 0.0557) + (y * -0.2040) + (z * 1.0570);\n\n\t// assume sRGB\n\tr = r > 0.0031308\n\t\t? ((1.055 * Math.pow(r, 1.0 / 2.4)) - 0.055)\n\t\t: r * 12.92;\n\n\tg = g > 0.0031308\n\t\t? ((1.055 * Math.pow(g, 1.0 / 2.4)) - 0.055)\n\t\t: g * 12.92;\n\n\tb = b > 0.0031308\n\t\t? ((1.055 * Math.pow(b, 1.0 / 2.4)) - 0.055)\n\t\t: b * 12.92;\n\n\tr = Math.min(Math.max(0, r), 1);\n\tg = Math.min(Math.max(0, g), 1);\n\tb = Math.min(Math.max(0, b), 1);\n\n\treturn [r * 255, g * 255, b * 255];\n};\n\nconvert.xyz.lab = function (xyz) {\n\tvar x = xyz[0];\n\tvar y = xyz[1];\n\tvar z = xyz[2];\n\tvar l;\n\tvar a;\n\tvar b;\n\n\tx /= 95.047;\n\ty /= 100;\n\tz /= 108.883;\n\n\tx = x > 0.008856 ? Math.pow(x, 1 / 3) : (7.787 * x) + (16 / 116);\n\ty = y > 0.008856 ? Math.pow(y, 1 / 3) : (7.787 * y) + (16 / 116);\n\tz = z > 0.008856 ? Math.pow(z, 1 / 3) : (7.787 * z) + (16 / 116);\n\n\tl = (116 * y) - 16;\n\ta = 500 * (x - y);\n\tb = 200 * (y - z);\n\n\treturn [l, a, b];\n};\n\nconvert.lab.xyz = function (lab) {\n\tvar l = lab[0];\n\tvar a = lab[1];\n\tvar b = lab[2];\n\tvar x;\n\tvar y;\n\tvar z;\n\n\ty = (l + 16) / 116;\n\tx = a / 500 + y;\n\tz = y - b / 200;\n\n\tvar y2 = Math.pow(y, 3);\n\tvar x2 = Math.pow(x, 3);\n\tvar z2 = Math.pow(z, 3);\n\ty = y2 > 0.008856 ? y2 : (y - 16 / 116) / 7.787;\n\tx = x2 > 0.008856 ? x2 : (x - 16 / 116) / 7.787;\n\tz = z2 > 0.008856 ? z2 : (z - 16 / 116) / 7.787;\n\n\tx *= 95.047;\n\ty *= 100;\n\tz *= 108.883;\n\n\treturn [x, y, z];\n};\n\nconvert.lab.lch = function (lab) {\n\tvar l = lab[0];\n\tvar a = lab[1];\n\tvar b = lab[2];\n\tvar hr;\n\tvar h;\n\tvar c;\n\n\thr = Math.atan2(b, a);\n\th = hr * 360 / 2 / Math.PI;\n\n\tif (h < 0) {\n\t\th += 360;\n\t}\n\n\tc = Math.sqrt(a * a + b * b);\n\n\treturn [l, c, h];\n};\n\nconvert.lch.lab = function (lch) {\n\tvar l = lch[0];\n\tvar c = lch[1];\n\tvar h = lch[2];\n\tvar a;\n\tvar b;\n\tvar hr;\n\n\thr = h / 360 * 2 * Math.PI;\n\ta = c * Math.cos(hr);\n\tb = c * Math.sin(hr);\n\n\treturn [l, a, b];\n};\n\nconvert.rgb.ansi16 = function (args) {\n\tvar r = args[0];\n\tvar g = args[1];\n\tvar b = args[2];\n\tvar value = 1 in arguments ? arguments[1] : convert.rgb.hsv(args)[2]; // hsv -> ansi16 optimization\n\n\tvalue = Math.round(value / 50);\n\n\tif (value === 0) {\n\t\treturn 30;\n\t}\n\n\tvar ansi = 30\n\t\t+ ((Math.round(b / 255) << 2)\n\t\t| (Math.round(g / 255) << 1)\n\t\t| Math.round(r / 255));\n\n\tif (value === 2) {\n\t\tansi += 60;\n\t}\n\n\treturn ansi;\n};\n\nconvert.hsv.ansi16 = function (args) {\n\t// optimization here; we already know the value and don't need to get\n\t// it converted for us.\n\treturn convert.rgb.ansi16(convert.hsv.rgb(args), args[2]);\n};\n\nconvert.rgb.ansi256 = function (args) {\n\tvar r = args[0];\n\tvar g = args[1];\n\tvar b = args[2];\n\n\t// we use the extended greyscale palette here, with the exception of\n\t// black and white. normal palette only has 4 greyscale shades.\n\tif (r === g && g === b) {\n\t\tif (r < 8) {\n\t\t\treturn 16;\n\t\t}\n\n\t\tif (r > 248) {\n\t\t\treturn 231;\n\t\t}\n\n\t\treturn Math.round(((r - 8) / 247) * 24) + 232;\n\t}\n\n\tvar ansi = 16\n\t\t+ (36 * Math.round(r / 255 * 5))\n\t\t+ (6 * Math.round(g / 255 * 5))\n\t\t+ Math.round(b / 255 * 5);\n\n\treturn ansi;\n};\n\nconvert.ansi16.rgb = function (args) {\n\tvar color = args % 10;\n\n\t// handle greyscale\n\tif (color === 0 || color === 7) {\n\t\tif (args > 50) {\n\t\t\tcolor += 3.5;\n\t\t}\n\n\t\tcolor = color / 10.5 * 255;\n\n\t\treturn [color, color, color];\n\t}\n\n\tvar mult = (~~(args > 50) + 1) * 0.5;\n\tvar r = ((color & 1) * mult) * 255;\n\tvar g = (((color >> 1) & 1) * mult) * 255;\n\tvar b = (((color >> 2) & 1) * mult) * 255;\n\n\treturn [r, g, b];\n};\n\nconvert.ansi256.rgb = function (args) {\n\t// handle greyscale\n\tif (args >= 232) {\n\t\tvar c = (args - 232) * 10 + 8;\n\t\treturn [c, c, c];\n\t}\n\n\targs -= 16;\n\n\tvar rem;\n\tvar r = Math.floor(args / 36) / 5 * 255;\n\tvar g = Math.floor((rem = args % 36) / 6) / 5 * 255;\n\tvar b = (rem % 6) / 5 * 255;\n\n\treturn [r, g, b];\n};\n\nconvert.rgb.hex = function (args) {\n\tvar integer = ((Math.round(args[0]) & 0xFF) << 16)\n\t\t+ ((Math.round(args[1]) & 0xFF) << 8)\n\t\t+ (Math.round(args[2]) & 0xFF);\n\n\tvar string = integer.toString(16).toUpperCase();\n\treturn '000000'.substring(string.length) + string;\n};\n\nconvert.hex.rgb = function (args) {\n\tvar match = args.toString(16).match(/[a-f0-9]{6}|[a-f0-9]{3}/i);\n\tif (!match) {\n\t\treturn [0, 0, 0];\n\t}\n\n\tvar colorString = match[0];\n\n\tif (match[0].length === 3) {\n\t\tcolorString = colorString.split('').map(function (char) {\n\t\t\treturn char + char;\n\t\t}).join('');\n\t}\n\n\tvar integer = parseInt(colorString, 16);\n\tvar r = (integer >> 16) & 0xFF;\n\tvar g = (integer >> 8) & 0xFF;\n\tvar b = integer & 0xFF;\n\n\treturn [r, g, b];\n};\n\nconvert.rgb.hcg = function (rgb) {\n\tvar r = rgb[0] / 255;\n\tvar g = rgb[1] / 255;\n\tvar b = rgb[2] / 255;\n\tvar max = Math.max(Math.max(r, g), b);\n\tvar min = Math.min(Math.min(r, g), b);\n\tvar chroma = (max - min);\n\tvar grayscale;\n\tvar hue;\n\n\tif (chroma < 1) {\n\t\tgrayscale = min / (1 - chroma);\n\t} else {\n\t\tgrayscale = 0;\n\t}\n\n\tif (chroma <= 0) {\n\t\thue = 0;\n\t} else\n\tif (max === r) {\n\t\thue = ((g - b) / chroma) % 6;\n\t} else\n\tif (max === g) {\n\t\thue = 2 + (b - r) / chroma;\n\t} else {\n\t\thue = 4 + (r - g) / chroma + 4;\n\t}\n\n\thue /= 6;\n\thue %= 1;\n\n\treturn [hue * 360, chroma * 100, grayscale * 100];\n};\n\nconvert.hsl.hcg = function (hsl) {\n\tvar s = hsl[1] / 100;\n\tvar l = hsl[2] / 100;\n\tvar c = 1;\n\tvar f = 0;\n\n\tif (l < 0.5) {\n\t\tc = 2.0 * s * l;\n\t} else {\n\t\tc = 2.0 * s * (1.0 - l);\n\t}\n\n\tif (c < 1.0) {\n\t\tf = (l - 0.5 * c) / (1.0 - c);\n\t}\n\n\treturn [hsl[0], c * 100, f * 100];\n};\n\nconvert.hsv.hcg = function (hsv) {\n\tvar s = hsv[1] / 100;\n\tvar v = hsv[2] / 100;\n\n\tvar c = s * v;\n\tvar f = 0;\n\n\tif (c < 1.0) {\n\t\tf = (v - c) / (1 - c);\n\t}\n\n\treturn [hsv[0], c * 100, f * 100];\n};\n\nconvert.hcg.rgb = function (hcg) {\n\tvar h = hcg[0] / 360;\n\tvar c = hcg[1] / 100;\n\tvar g = hcg[2] / 100;\n\n\tif (c === 0.0) {\n\t\treturn [g * 255, g * 255, g * 255];\n\t}\n\n\tvar pure = [0, 0, 0];\n\tvar hi = (h % 1) * 6;\n\tvar v = hi % 1;\n\tvar w = 1 - v;\n\tvar mg = 0;\n\n\tswitch (Math.floor(hi)) {\n\t\tcase 0:\n\t\t\tpure[0] = 1; pure[1] = v; pure[2] = 0; break;\n\t\tcase 1:\n\t\t\tpure[0] = w; pure[1] = 1; pure[2] = 0; break;\n\t\tcase 2:\n\t\t\tpure[0] = 0; pure[1] = 1; pure[2] = v; break;\n\t\tcase 3:\n\t\t\tpure[0] = 0; pure[1] = w; pure[2] = 1; break;\n\t\tcase 4:\n\t\t\tpure[0] = v; pure[1] = 0; pure[2] = 1; break;\n\t\tdefault:\n\t\t\tpure[0] = 1; pure[1] = 0; pure[2] = w;\n\t}\n\n\tmg = (1.0 - c) * g;\n\n\treturn [\n\t\t(c * pure[0] + mg) * 255,\n\t\t(c * pure[1] + mg) * 255,\n\t\t(c * pure[2] + mg) * 255\n\t];\n};\n\nconvert.hcg.hsv = function (hcg) {\n\tvar c = hcg[1] / 100;\n\tvar g = hcg[2] / 100;\n\n\tvar v = c + g * (1.0 - c);\n\tvar f = 0;\n\n\tif (v > 0.0) {\n\t\tf = c / v;\n\t}\n\n\treturn [hcg[0], f * 100, v * 100];\n};\n\nconvert.hcg.hsl = function (hcg) {\n\tvar c = hcg[1] / 100;\n\tvar g = hcg[2] / 100;\n\n\tvar l = g * (1.0 - c) + 0.5 * c;\n\tvar s = 0;\n\n\tif (l > 0.0 && l < 0.5) {\n\t\ts = c / (2 * l);\n\t} else\n\tif (l >= 0.5 && l < 1.0) {\n\t\ts = c / (2 * (1 - l));\n\t}\n\n\treturn [hcg[0], s * 100, l * 100];\n};\n\nconvert.hcg.hwb = function (hcg) {\n\tvar c = hcg[1] / 100;\n\tvar g = hcg[2] / 100;\n\tvar v = c + g * (1.0 - c);\n\treturn [hcg[0], (v - c) * 100, (1 - v) * 100];\n};\n\nconvert.hwb.hcg = function (hwb) {\n\tvar w = hwb[1] / 100;\n\tvar b = hwb[2] / 100;\n\tvar v = 1 - b;\n\tvar c = v - w;\n\tvar g = 0;\n\n\tif (c < 1) {\n\t\tg = (v - c) / (1 - c);\n\t}\n\n\treturn [hwb[0], c * 100, g * 100];\n};\n\nconvert.apple.rgb = function (apple) {\n\treturn [(apple[0] / 65535) * 255, (apple[1] / 65535) * 255, (apple[2] / 65535) * 255];\n};\n\nconvert.rgb.apple = function (rgb) {\n\treturn [(rgb[0] / 255) * 65535, (rgb[1] / 255) * 65535, (rgb[2] / 255) * 65535];\n};\n\nconvert.gray.rgb = function (args) {\n\treturn [args[0] / 100 * 255, args[0] / 100 * 255, args[0] / 100 * 255];\n};\n\nconvert.gray.hsl = convert.gray.hsv = function (args) {\n\treturn [0, 0, args[0]];\n};\n\nconvert.gray.hwb = function (gray) {\n\treturn [0, 100, gray[0]];\n};\n\nconvert.gray.cmyk = function (gray) {\n\treturn [0, 0, 0, gray[0]];\n};\n\nconvert.gray.lab = function (gray) {\n\treturn [gray[0], 0, 0];\n};\n\nconvert.gray.hex = function (gray) {\n\tvar val = Math.round(gray[0] / 100 * 255) & 0xFF;\n\tvar integer = (val << 16) + (val << 8) + val;\n\n\tvar string = integer.toString(16).toUpperCase();\n\treturn '000000'.substring(string.length) + string;\n};\n\nconvert.rgb.gray = function (rgb) {\n\tvar val = (rgb[0] + rgb[1] + rgb[2]) / 3;\n\treturn [val / 255 * 100];\n};\n\n\n//# sourceURL=webpack:///./node_modules/color-convert/conversions.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/color-convert/index.js":
|
|
/*!*********************************************!*\
|
|
!*** ./node_modules/color-convert/index.js ***!
|
|
\*********************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
eval("var conversions = __webpack_require__(/*! ./conversions */ \"./node_modules/color-convert/conversions.js\");\nvar route = __webpack_require__(/*! ./route */ \"./node_modules/color-convert/route.js\");\n\nvar convert = {};\n\nvar models = Object.keys(conversions);\n\nfunction wrapRaw(fn) {\n\tvar wrappedFn = function (args) {\n\t\tif (args === undefined || args === null) {\n\t\t\treturn args;\n\t\t}\n\n\t\tif (arguments.length > 1) {\n\t\t\targs = Array.prototype.slice.call(arguments);\n\t\t}\n\n\t\treturn fn(args);\n\t};\n\n\t// preserve .conversion property if there is one\n\tif ('conversion' in fn) {\n\t\twrappedFn.conversion = fn.conversion;\n\t}\n\n\treturn wrappedFn;\n}\n\nfunction wrapRounded(fn) {\n\tvar wrappedFn = function (args) {\n\t\tif (args === undefined || args === null) {\n\t\t\treturn args;\n\t\t}\n\n\t\tif (arguments.length > 1) {\n\t\t\targs = Array.prototype.slice.call(arguments);\n\t\t}\n\n\t\tvar result = fn(args);\n\n\t\t// we're assuming the result is an array here.\n\t\t// see notice in conversions.js; don't use box types\n\t\t// in conversion functions.\n\t\tif (typeof result === 'object') {\n\t\t\tfor (var len = result.length, i = 0; i < len; i++) {\n\t\t\t\tresult[i] = Math.round(result[i]);\n\t\t\t}\n\t\t}\n\n\t\treturn result;\n\t};\n\n\t// preserve .conversion property if there is one\n\tif ('conversion' in fn) {\n\t\twrappedFn.conversion = fn.conversion;\n\t}\n\n\treturn wrappedFn;\n}\n\nmodels.forEach(function (fromModel) {\n\tconvert[fromModel] = {};\n\n\tObject.defineProperty(convert[fromModel], 'channels', {value: conversions[fromModel].channels});\n\tObject.defineProperty(convert[fromModel], 'labels', {value: conversions[fromModel].labels});\n\n\tvar routes = route(fromModel);\n\tvar routeModels = Object.keys(routes);\n\n\trouteModels.forEach(function (toModel) {\n\t\tvar fn = routes[toModel];\n\n\t\tconvert[fromModel][toModel] = wrapRounded(fn);\n\t\tconvert[fromModel][toModel].raw = wrapRaw(fn);\n\t});\n});\n\nmodule.exports = convert;\n\n\n//# sourceURL=webpack:///./node_modules/color-convert/index.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/color-convert/route.js":
|
|
/*!*********************************************!*\
|
|
!*** ./node_modules/color-convert/route.js ***!
|
|
\*********************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
eval("var conversions = __webpack_require__(/*! ./conversions */ \"./node_modules/color-convert/conversions.js\");\n\n/*\n\tthis function routes a model to all other models.\n\n\tall functions that are routed have a property `.conversion` attached\n\tto the returned synthetic function. This property is an array\n\tof strings, each with the steps in between the 'from' and 'to'\n\tcolor models (inclusive).\n\n\tconversions that are not possible simply are not included.\n*/\n\nfunction buildGraph() {\n\tvar graph = {};\n\t// https://jsperf.com/object-keys-vs-for-in-with-closure/3\n\tvar models = Object.keys(conversions);\n\n\tfor (var len = models.length, i = 0; i < len; i++) {\n\t\tgraph[models[i]] = {\n\t\t\t// http://jsperf.com/1-vs-infinity\n\t\t\t// micro-opt, but this is simple.\n\t\t\tdistance: -1,\n\t\t\tparent: null\n\t\t};\n\t}\n\n\treturn graph;\n}\n\n// https://en.wikipedia.org/wiki/Breadth-first_search\nfunction deriveBFS(fromModel) {\n\tvar graph = buildGraph();\n\tvar queue = [fromModel]; // unshift -> queue -> pop\n\n\tgraph[fromModel].distance = 0;\n\n\twhile (queue.length) {\n\t\tvar current = queue.pop();\n\t\tvar adjacents = Object.keys(conversions[current]);\n\n\t\tfor (var len = adjacents.length, i = 0; i < len; i++) {\n\t\t\tvar adjacent = adjacents[i];\n\t\t\tvar node = graph[adjacent];\n\n\t\t\tif (node.distance === -1) {\n\t\t\t\tnode.distance = graph[current].distance + 1;\n\t\t\t\tnode.parent = current;\n\t\t\t\tqueue.unshift(adjacent);\n\t\t\t}\n\t\t}\n\t}\n\n\treturn graph;\n}\n\nfunction link(from, to) {\n\treturn function (args) {\n\t\treturn to(from(args));\n\t};\n}\n\nfunction wrapConversion(toModel, graph) {\n\tvar path = [graph[toModel].parent, toModel];\n\tvar fn = conversions[graph[toModel].parent][toModel];\n\n\tvar cur = graph[toModel].parent;\n\twhile (graph[cur].parent) {\n\t\tpath.unshift(graph[cur].parent);\n\t\tfn = link(conversions[graph[cur].parent][cur], fn);\n\t\tcur = graph[cur].parent;\n\t}\n\n\tfn.conversion = path;\n\treturn fn;\n}\n\nmodule.exports = function (fromModel) {\n\tvar graph = deriveBFS(fromModel);\n\tvar conversion = {};\n\n\tvar models = Object.keys(graph);\n\tfor (var len = models.length, i = 0; i < len; i++) {\n\t\tvar toModel = models[i];\n\t\tvar node = graph[toModel];\n\n\t\tif (node.parent === null) {\n\t\t\t// no possible conversion, or this node is the source model.\n\t\t\tcontinue;\n\t\t}\n\n\t\tconversion[toModel] = wrapConversion(toModel, graph);\n\t}\n\n\treturn conversion;\n};\n\n\n\n//# sourceURL=webpack:///./node_modules/color-convert/route.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/color-name/index.js":
|
|
/*!******************************************!*\
|
|
!*** ./node_modules/color-name/index.js ***!
|
|
\******************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\r\n\r\nmodule.exports = {\r\n\t\"aliceblue\": [240, 248, 255],\r\n\t\"antiquewhite\": [250, 235, 215],\r\n\t\"aqua\": [0, 255, 255],\r\n\t\"aquamarine\": [127, 255, 212],\r\n\t\"azure\": [240, 255, 255],\r\n\t\"beige\": [245, 245, 220],\r\n\t\"bisque\": [255, 228, 196],\r\n\t\"black\": [0, 0, 0],\r\n\t\"blanchedalmond\": [255, 235, 205],\r\n\t\"blue\": [0, 0, 255],\r\n\t\"blueviolet\": [138, 43, 226],\r\n\t\"brown\": [165, 42, 42],\r\n\t\"burlywood\": [222, 184, 135],\r\n\t\"cadetblue\": [95, 158, 160],\r\n\t\"chartreuse\": [127, 255, 0],\r\n\t\"chocolate\": [210, 105, 30],\r\n\t\"coral\": [255, 127, 80],\r\n\t\"cornflowerblue\": [100, 149, 237],\r\n\t\"cornsilk\": [255, 248, 220],\r\n\t\"crimson\": [220, 20, 60],\r\n\t\"cyan\": [0, 255, 255],\r\n\t\"darkblue\": [0, 0, 139],\r\n\t\"darkcyan\": [0, 139, 139],\r\n\t\"darkgoldenrod\": [184, 134, 11],\r\n\t\"darkgray\": [169, 169, 169],\r\n\t\"darkgreen\": [0, 100, 0],\r\n\t\"darkgrey\": [169, 169, 169],\r\n\t\"darkkhaki\": [189, 183, 107],\r\n\t\"darkmagenta\": [139, 0, 139],\r\n\t\"darkolivegreen\": [85, 107, 47],\r\n\t\"darkorange\": [255, 140, 0],\r\n\t\"darkorchid\": [153, 50, 204],\r\n\t\"darkred\": [139, 0, 0],\r\n\t\"darksalmon\": [233, 150, 122],\r\n\t\"darkseagreen\": [143, 188, 143],\r\n\t\"darkslateblue\": [72, 61, 139],\r\n\t\"darkslategray\": [47, 79, 79],\r\n\t\"darkslategrey\": [47, 79, 79],\r\n\t\"darkturquoise\": [0, 206, 209],\r\n\t\"darkviolet\": [148, 0, 211],\r\n\t\"deeppink\": [255, 20, 147],\r\n\t\"deepskyblue\": [0, 191, 255],\r\n\t\"dimgray\": [105, 105, 105],\r\n\t\"dimgrey\": [105, 105, 105],\r\n\t\"dodgerblue\": [30, 144, 255],\r\n\t\"firebrick\": [178, 34, 34],\r\n\t\"floralwhite\": [255, 250, 240],\r\n\t\"forestgreen\": [34, 139, 34],\r\n\t\"fuchsia\": [255, 0, 255],\r\n\t\"gainsboro\": [220, 220, 220],\r\n\t\"ghostwhite\": [248, 248, 255],\r\n\t\"gold\": [255, 215, 0],\r\n\t\"goldenrod\": [218, 165, 32],\r\n\t\"gray\": [128, 128, 128],\r\n\t\"green\": [0, 128, 0],\r\n\t\"greenyellow\": [173, 255, 47],\r\n\t\"grey\": [128, 128, 128],\r\n\t\"honeydew\": [240, 255, 240],\r\n\t\"hotpink\": [255, 105, 180],\r\n\t\"indianred\": [205, 92, 92],\r\n\t\"indigo\": [75, 0, 130],\r\n\t\"ivory\": [255, 255, 240],\r\n\t\"khaki\": [240, 230, 140],\r\n\t\"lavender\": [230, 230, 250],\r\n\t\"lavenderblush\": [255, 240, 245],\r\n\t\"lawngreen\": [124, 252, 0],\r\n\t\"lemonchiffon\": [255, 250, 205],\r\n\t\"lightblue\": [173, 216, 230],\r\n\t\"lightcoral\": [240, 128, 128],\r\n\t\"lightcyan\": [224, 255, 255],\r\n\t\"lightgoldenrodyellow\": [250, 250, 210],\r\n\t\"lightgray\": [211, 211, 211],\r\n\t\"lightgreen\": [144, 238, 144],\r\n\t\"lightgrey\": [211, 211, 211],\r\n\t\"lightpink\": [255, 182, 193],\r\n\t\"lightsalmon\": [255, 160, 122],\r\n\t\"lightseagreen\": [32, 178, 170],\r\n\t\"lightskyblue\": [135, 206, 250],\r\n\t\"lightslategray\": [119, 136, 153],\r\n\t\"lightslategrey\": [119, 136, 153],\r\n\t\"lightsteelblue\": [176, 196, 222],\r\n\t\"lightyellow\": [255, 255, 224],\r\n\t\"lime\": [0, 255, 0],\r\n\t\"limegreen\": [50, 205, 50],\r\n\t\"linen\": [250, 240, 230],\r\n\t\"magenta\": [255, 0, 255],\r\n\t\"maroon\": [128, 0, 0],\r\n\t\"mediumaquamarine\": [102, 205, 170],\r\n\t\"mediumblue\": [0, 0, 205],\r\n\t\"mediumorchid\": [186, 85, 211],\r\n\t\"mediumpurple\": [147, 112, 219],\r\n\t\"mediumseagreen\": [60, 179, 113],\r\n\t\"mediumslateblue\": [123, 104, 238],\r\n\t\"mediumspringgreen\": [0, 250, 154],\r\n\t\"mediumturquoise\": [72, 209, 204],\r\n\t\"mediumvioletred\": [199, 21, 133],\r\n\t\"midnightblue\": [25, 25, 112],\r\n\t\"mintcream\": [245, 255, 250],\r\n\t\"mistyrose\": [255, 228, 225],\r\n\t\"moccasin\": [255, 228, 181],\r\n\t\"navajowhite\": [255, 222, 173],\r\n\t\"navy\": [0, 0, 128],\r\n\t\"oldlace\": [253, 245, 230],\r\n\t\"olive\": [128, 128, 0],\r\n\t\"olivedrab\": [107, 142, 35],\r\n\t\"orange\": [255, 165, 0],\r\n\t\"orangered\": [255, 69, 0],\r\n\t\"orchid\": [218, 112, 214],\r\n\t\"palegoldenrod\": [238, 232, 170],\r\n\t\"palegreen\": [152, 251, 152],\r\n\t\"paleturquoise\": [175, 238, 238],\r\n\t\"palevioletred\": [219, 112, 147],\r\n\t\"papayawhip\": [255, 239, 213],\r\n\t\"peachpuff\": [255, 218, 185],\r\n\t\"peru\": [205, 133, 63],\r\n\t\"pink\": [255, 192, 203],\r\n\t\"plum\": [221, 160, 221],\r\n\t\"powderblue\": [176, 224, 230],\r\n\t\"purple\": [128, 0, 128],\r\n\t\"rebeccapurple\": [102, 51, 153],\r\n\t\"red\": [255, 0, 0],\r\n\t\"rosybrown\": [188, 143, 143],\r\n\t\"royalblue\": [65, 105, 225],\r\n\t\"saddlebrown\": [139, 69, 19],\r\n\t\"salmon\": [250, 128, 114],\r\n\t\"sandybrown\": [244, 164, 96],\r\n\t\"seagreen\": [46, 139, 87],\r\n\t\"seashell\": [255, 245, 238],\r\n\t\"sienna\": [160, 82, 45],\r\n\t\"silver\": [192, 192, 192],\r\n\t\"skyblue\": [135, 206, 235],\r\n\t\"slateblue\": [106, 90, 205],\r\n\t\"slategray\": [112, 128, 144],\r\n\t\"slategrey\": [112, 128, 144],\r\n\t\"snow\": [255, 250, 250],\r\n\t\"springgreen\": [0, 255, 127],\r\n\t\"steelblue\": [70, 130, 180],\r\n\t\"tan\": [210, 180, 140],\r\n\t\"teal\": [0, 128, 128],\r\n\t\"thistle\": [216, 191, 216],\r\n\t\"tomato\": [255, 99, 71],\r\n\t\"turquoise\": [64, 224, 208],\r\n\t\"violet\": [238, 130, 238],\r\n\t\"wheat\": [245, 222, 179],\r\n\t\"white\": [255, 255, 255],\r\n\t\"whitesmoke\": [245, 245, 245],\r\n\t\"yellow\": [255, 255, 0],\r\n\t\"yellowgreen\": [154, 205, 50]\r\n};\r\n\n\n//# sourceURL=webpack:///./node_modules/color-name/index.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/color-string/index.js":
|
|
/*!********************************************!*\
|
|
!*** ./node_modules/color-string/index.js ***!
|
|
\********************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
eval("/* MIT license */\nvar colorNames = __webpack_require__(/*! color-name */ \"./node_modules/color-name/index.js\");\nvar swizzle = __webpack_require__(/*! simple-swizzle */ \"./node_modules/simple-swizzle/index.js\");\n\nvar reverseNames = {};\n\n// create a list of reverse color names\nfor (var name in colorNames) {\n\tif (colorNames.hasOwnProperty(name)) {\n\t\treverseNames[colorNames[name]] = name;\n\t}\n}\n\nvar cs = module.exports = {\n\tto: {},\n\tget: {}\n};\n\ncs.get = function (string) {\n\tvar prefix = string.substring(0, 3).toLowerCase();\n\tvar val;\n\tvar model;\n\tswitch (prefix) {\n\t\tcase 'hsl':\n\t\t\tval = cs.get.hsl(string);\n\t\t\tmodel = 'hsl';\n\t\t\tbreak;\n\t\tcase 'hwb':\n\t\t\tval = cs.get.hwb(string);\n\t\t\tmodel = 'hwb';\n\t\t\tbreak;\n\t\tdefault:\n\t\t\tval = cs.get.rgb(string);\n\t\t\tmodel = 'rgb';\n\t\t\tbreak;\n\t}\n\n\tif (!val) {\n\t\treturn null;\n\t}\n\n\treturn {model: model, value: val};\n};\n\ncs.get.rgb = function (string) {\n\tif (!string) {\n\t\treturn null;\n\t}\n\n\tvar abbr = /^#([a-f0-9]{3,4})$/i;\n\tvar hex = /^#([a-f0-9]{6})([a-f0-9]{2})?$/i;\n\tvar rgba = /^rgba?\\(\\s*([+-]?\\d+)\\s*,\\s*([+-]?\\d+)\\s*,\\s*([+-]?\\d+)\\s*(?:,\\s*([+-]?[\\d\\.]+)\\s*)?\\)$/;\n\tvar per = /^rgba?\\(\\s*([+-]?[\\d\\.]+)\\%\\s*,\\s*([+-]?[\\d\\.]+)\\%\\s*,\\s*([+-]?[\\d\\.]+)\\%\\s*(?:,\\s*([+-]?[\\d\\.]+)\\s*)?\\)$/;\n\tvar keyword = /(\\D+)/;\n\n\tvar rgb = [0, 0, 0, 1];\n\tvar match;\n\tvar i;\n\tvar hexAlpha;\n\n\tif (match = string.match(hex)) {\n\t\thexAlpha = match[2];\n\t\tmatch = match[1];\n\n\t\tfor (i = 0; i < 3; i++) {\n\t\t\t// https://jsperf.com/slice-vs-substr-vs-substring-methods-long-string/19\n\t\t\tvar i2 = i * 2;\n\t\t\trgb[i] = parseInt(match.slice(i2, i2 + 2), 16);\n\t\t}\n\n\t\tif (hexAlpha) {\n\t\t\trgb[3] = Math.round((parseInt(hexAlpha, 16) / 255) * 100) / 100;\n\t\t}\n\t} else if (match = string.match(abbr)) {\n\t\tmatch = match[1];\n\t\thexAlpha = match[3];\n\n\t\tfor (i = 0; i < 3; i++) {\n\t\t\trgb[i] = parseInt(match[i] + match[i], 16);\n\t\t}\n\n\t\tif (hexAlpha) {\n\t\t\trgb[3] = Math.round((parseInt(hexAlpha + hexAlpha, 16) / 255) * 100) / 100;\n\t\t}\n\t} else if (match = string.match(rgba)) {\n\t\tfor (i = 0; i < 3; i++) {\n\t\t\trgb[i] = parseInt(match[i + 1], 0);\n\t\t}\n\n\t\tif (match[4]) {\n\t\t\trgb[3] = parseFloat(match[4]);\n\t\t}\n\t} else if (match = string.match(per)) {\n\t\tfor (i = 0; i < 3; i++) {\n\t\t\trgb[i] = Math.round(parseFloat(match[i + 1]) * 2.55);\n\t\t}\n\n\t\tif (match[4]) {\n\t\t\trgb[3] = parseFloat(match[4]);\n\t\t}\n\t} else if (match = string.match(keyword)) {\n\t\tif (match[1] === 'transparent') {\n\t\t\treturn [0, 0, 0, 0];\n\t\t}\n\n\t\trgb = colorNames[match[1]];\n\n\t\tif (!rgb) {\n\t\t\treturn null;\n\t\t}\n\n\t\trgb[3] = 1;\n\n\t\treturn rgb;\n\t} else {\n\t\treturn null;\n\t}\n\n\tfor (i = 0; i < 3; i++) {\n\t\trgb[i] = clamp(rgb[i], 0, 255);\n\t}\n\trgb[3] = clamp(rgb[3], 0, 1);\n\n\treturn rgb;\n};\n\ncs.get.hsl = function (string) {\n\tif (!string) {\n\t\treturn null;\n\t}\n\n\tvar hsl = /^hsla?\\(\\s*([+-]?(?:\\d*\\.)?\\d+)(?:deg)?\\s*,\\s*([+-]?[\\d\\.]+)%\\s*,\\s*([+-]?[\\d\\.]+)%\\s*(?:,\\s*([+-]?[\\d\\.]+)\\s*)?\\)$/;\n\tvar match = string.match(hsl);\n\n\tif (match) {\n\t\tvar alpha = parseFloat(match[4]);\n\t\tvar h = (parseFloat(match[1]) + 360) % 360;\n\t\tvar s = clamp(parseFloat(match[2]), 0, 100);\n\t\tvar l = clamp(parseFloat(match[3]), 0, 100);\n\t\tvar a = clamp(isNaN(alpha) ? 1 : alpha, 0, 1);\n\n\t\treturn [h, s, l, a];\n\t}\n\n\treturn null;\n};\n\ncs.get.hwb = function (string) {\n\tif (!string) {\n\t\treturn null;\n\t}\n\n\tvar hwb = /^hwb\\(\\s*([+-]?\\d*[\\.]?\\d+)(?:deg)?\\s*,\\s*([+-]?[\\d\\.]+)%\\s*,\\s*([+-]?[\\d\\.]+)%\\s*(?:,\\s*([+-]?[\\d\\.]+)\\s*)?\\)$/;\n\tvar match = string.match(hwb);\n\n\tif (match) {\n\t\tvar alpha = parseFloat(match[4]);\n\t\tvar h = ((parseFloat(match[1]) % 360) + 360) % 360;\n\t\tvar w = clamp(parseFloat(match[2]), 0, 100);\n\t\tvar b = clamp(parseFloat(match[3]), 0, 100);\n\t\tvar a = clamp(isNaN(alpha) ? 1 : alpha, 0, 1);\n\t\treturn [h, w, b, a];\n\t}\n\n\treturn null;\n};\n\ncs.to.hex = function () {\n\tvar rgba = swizzle(arguments);\n\n\treturn (\n\t\t'#' +\n\t\thexDouble(rgba[0]) +\n\t\thexDouble(rgba[1]) +\n\t\thexDouble(rgba[2]) +\n\t\t(rgba[3] < 1\n\t\t\t? (hexDouble(Math.round(rgba[3] * 255)))\n\t\t\t: '')\n\t);\n};\n\ncs.to.rgb = function () {\n\tvar rgba = swizzle(arguments);\n\n\treturn rgba.length < 4 || rgba[3] === 1\n\t\t? 'rgb(' + Math.round(rgba[0]) + ', ' + Math.round(rgba[1]) + ', ' + Math.round(rgba[2]) + ')'\n\t\t: 'rgba(' + Math.round(rgba[0]) + ', ' + Math.round(rgba[1]) + ', ' + Math.round(rgba[2]) + ', ' + rgba[3] + ')';\n};\n\ncs.to.rgb.percent = function () {\n\tvar rgba = swizzle(arguments);\n\n\tvar r = Math.round(rgba[0] / 255 * 100);\n\tvar g = Math.round(rgba[1] / 255 * 100);\n\tvar b = Math.round(rgba[2] / 255 * 100);\n\n\treturn rgba.length < 4 || rgba[3] === 1\n\t\t? 'rgb(' + r + '%, ' + g + '%, ' + b + '%)'\n\t\t: 'rgba(' + r + '%, ' + g + '%, ' + b + '%, ' + rgba[3] + ')';\n};\n\ncs.to.hsl = function () {\n\tvar hsla = swizzle(arguments);\n\treturn hsla.length < 4 || hsla[3] === 1\n\t\t? 'hsl(' + hsla[0] + ', ' + hsla[1] + '%, ' + hsla[2] + '%)'\n\t\t: 'hsla(' + hsla[0] + ', ' + hsla[1] + '%, ' + hsla[2] + '%, ' + hsla[3] + ')';\n};\n\n// hwb is a bit different than rgb(a) & hsl(a) since there is no alpha specific syntax\n// (hwb have alpha optional & 1 is default value)\ncs.to.hwb = function () {\n\tvar hwba = swizzle(arguments);\n\n\tvar a = '';\n\tif (hwba.length >= 4 && hwba[3] !== 1) {\n\t\ta = ', ' + hwba[3];\n\t}\n\n\treturn 'hwb(' + hwba[0] + ', ' + hwba[1] + '%, ' + hwba[2] + '%' + a + ')';\n};\n\ncs.to.keyword = function (rgb) {\n\treturn reverseNames[rgb.slice(0, 3)];\n};\n\n// helpers\nfunction clamp(num, min, max) {\n\treturn Math.min(Math.max(min, num), max);\n}\n\nfunction hexDouble(num) {\n\tvar str = num.toString(16).toUpperCase();\n\treturn (str.length < 2) ? '0' + str : str;\n}\n\n\n//# sourceURL=webpack:///./node_modules/color-string/index.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/color/index.js":
|
|
/*!*************************************!*\
|
|
!*** ./node_modules/color/index.js ***!
|
|
\*************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\nvar colorString = __webpack_require__(/*! color-string */ \"./node_modules/color-string/index.js\");\nvar convert = __webpack_require__(/*! color-convert */ \"./node_modules/color-convert/index.js\");\n\nvar _slice = [].slice;\n\nvar skippedModels = [\n\t// to be honest, I don't really feel like keyword belongs in color convert, but eh.\n\t'keyword',\n\n\t// gray conflicts with some method names, and has its own method defined.\n\t'gray',\n\n\t// shouldn't really be in color-convert either...\n\t'hex'\n];\n\nvar hashedModelKeys = {};\nObject.keys(convert).forEach(function (model) {\n\thashedModelKeys[_slice.call(convert[model].labels).sort().join('')] = model;\n});\n\nvar limiters = {};\n\nfunction Color(obj, model) {\n\tif (!(this instanceof Color)) {\n\t\treturn new Color(obj, model);\n\t}\n\n\tif (model && model in skippedModels) {\n\t\tmodel = null;\n\t}\n\n\tif (model && !(model in convert)) {\n\t\tthrow new Error('Unknown model: ' + model);\n\t}\n\n\tvar i;\n\tvar channels;\n\n\tif (obj == null) { // eslint-disable-line no-eq-null,eqeqeq\n\t\tthis.model = 'rgb';\n\t\tthis.color = [0, 0, 0];\n\t\tthis.valpha = 1;\n\t} else if (obj instanceof Color) {\n\t\tthis.model = obj.model;\n\t\tthis.color = obj.color.slice();\n\t\tthis.valpha = obj.valpha;\n\t} else if (typeof obj === 'string') {\n\t\tvar result = colorString.get(obj);\n\t\tif (result === null) {\n\t\t\tthrow new Error('Unable to parse color from string: ' + obj);\n\t\t}\n\n\t\tthis.model = result.model;\n\t\tchannels = convert[this.model].channels;\n\t\tthis.color = result.value.slice(0, channels);\n\t\tthis.valpha = typeof result.value[channels] === 'number' ? result.value[channels] : 1;\n\t} else if (obj.length) {\n\t\tthis.model = model || 'rgb';\n\t\tchannels = convert[this.model].channels;\n\t\tvar newArr = _slice.call(obj, 0, channels);\n\t\tthis.color = zeroArray(newArr, channels);\n\t\tthis.valpha = typeof obj[channels] === 'number' ? obj[channels] : 1;\n\t} else if (typeof obj === 'number') {\n\t\t// this is always RGB - can be converted later on.\n\t\tobj &= 0xFFFFFF;\n\t\tthis.model = 'rgb';\n\t\tthis.color = [\n\t\t\t(obj >> 16) & 0xFF,\n\t\t\t(obj >> 8) & 0xFF,\n\t\t\tobj & 0xFF\n\t\t];\n\t\tthis.valpha = 1;\n\t} else {\n\t\tthis.valpha = 1;\n\n\t\tvar keys = Object.keys(obj);\n\t\tif ('alpha' in obj) {\n\t\t\tkeys.splice(keys.indexOf('alpha'), 1);\n\t\t\tthis.valpha = typeof obj.alpha === 'number' ? obj.alpha : 0;\n\t\t}\n\n\t\tvar hashedKeys = keys.sort().join('');\n\t\tif (!(hashedKeys in hashedModelKeys)) {\n\t\t\tthrow new Error('Unable to parse color from object: ' + JSON.stringify(obj));\n\t\t}\n\n\t\tthis.model = hashedModelKeys[hashedKeys];\n\n\t\tvar labels = convert[this.model].labels;\n\t\tvar color = [];\n\t\tfor (i = 0; i < labels.length; i++) {\n\t\t\tcolor.push(obj[labels[i]]);\n\t\t}\n\n\t\tthis.color = zeroArray(color);\n\t}\n\n\t// perform limitations (clamping, etc.)\n\tif (limiters[this.model]) {\n\t\tchannels = convert[this.model].channels;\n\t\tfor (i = 0; i < channels; i++) {\n\t\t\tvar limit = limiters[this.model][i];\n\t\t\tif (limit) {\n\t\t\t\tthis.color[i] = limit(this.color[i]);\n\t\t\t}\n\t\t}\n\t}\n\n\tthis.valpha = Math.max(0, Math.min(1, this.valpha));\n\n\tif (Object.freeze) {\n\t\tObject.freeze(this);\n\t}\n}\n\nColor.prototype = {\n\ttoString: function () {\n\t\treturn this.string();\n\t},\n\n\ttoJSON: function () {\n\t\treturn this[this.model]();\n\t},\n\n\tstring: function (places) {\n\t\tvar self = this.model in colorString.to ? this : this.rgb();\n\t\tself = self.round(typeof places === 'number' ? places : 1);\n\t\tvar args = self.valpha === 1 ? self.color : self.color.concat(this.valpha);\n\t\treturn colorString.to[self.model](args);\n\t},\n\n\tpercentString: function (places) {\n\t\tvar self = this.rgb().round(typeof places === 'number' ? places : 1);\n\t\tvar args = self.valpha === 1 ? self.color : self.color.concat(this.valpha);\n\t\treturn colorString.to.rgb.percent(args);\n\t},\n\n\tarray: function () {\n\t\treturn this.valpha === 1 ? this.color.slice() : this.color.concat(this.valpha);\n\t},\n\n\tobject: function () {\n\t\tvar result = {};\n\t\tvar channels = convert[this.model].channels;\n\t\tvar labels = convert[this.model].labels;\n\n\t\tfor (var i = 0; i < channels; i++) {\n\t\t\tresult[labels[i]] = this.color[i];\n\t\t}\n\n\t\tif (this.valpha !== 1) {\n\t\t\tresult.alpha = this.valpha;\n\t\t}\n\n\t\treturn result;\n\t},\n\n\tunitArray: function () {\n\t\tvar rgb = this.rgb().color;\n\t\trgb[0] /= 255;\n\t\trgb[1] /= 255;\n\t\trgb[2] /= 255;\n\n\t\tif (this.valpha !== 1) {\n\t\t\trgb.push(this.valpha);\n\t\t}\n\n\t\treturn rgb;\n\t},\n\n\tunitObject: function () {\n\t\tvar rgb = this.rgb().object();\n\t\trgb.r /= 255;\n\t\trgb.g /= 255;\n\t\trgb.b /= 255;\n\n\t\tif (this.valpha !== 1) {\n\t\t\trgb.alpha = this.valpha;\n\t\t}\n\n\t\treturn rgb;\n\t},\n\n\tround: function (places) {\n\t\tplaces = Math.max(places || 0, 0);\n\t\treturn new Color(this.color.map(roundToPlace(places)).concat(this.valpha), this.model);\n\t},\n\n\talpha: function (val) {\n\t\tif (arguments.length) {\n\t\t\treturn new Color(this.color.concat(Math.max(0, Math.min(1, val))), this.model);\n\t\t}\n\n\t\treturn this.valpha;\n\t},\n\n\t// rgb\n\tred: getset('rgb', 0, maxfn(255)),\n\tgreen: getset('rgb', 1, maxfn(255)),\n\tblue: getset('rgb', 2, maxfn(255)),\n\n\thue: getset(['hsl', 'hsv', 'hsl', 'hwb', 'hcg'], 0, function (val) { return ((val % 360) + 360) % 360; }), // eslint-disable-line brace-style\n\n\tsaturationl: getset('hsl', 1, maxfn(100)),\n\tlightness: getset('hsl', 2, maxfn(100)),\n\n\tsaturationv: getset('hsv', 1, maxfn(100)),\n\tvalue: getset('hsv', 2, maxfn(100)),\n\n\tchroma: getset('hcg', 1, maxfn(100)),\n\tgray: getset('hcg', 2, maxfn(100)),\n\n\twhite: getset('hwb', 1, maxfn(100)),\n\twblack: getset('hwb', 2, maxfn(100)),\n\n\tcyan: getset('cmyk', 0, maxfn(100)),\n\tmagenta: getset('cmyk', 1, maxfn(100)),\n\tyellow: getset('cmyk', 2, maxfn(100)),\n\tblack: getset('cmyk', 3, maxfn(100)),\n\n\tx: getset('xyz', 0, maxfn(100)),\n\ty: getset('xyz', 1, maxfn(100)),\n\tz: getset('xyz', 2, maxfn(100)),\n\n\tl: getset('lab', 0, maxfn(100)),\n\ta: getset('lab', 1),\n\tb: getset('lab', 2),\n\n\tkeyword: function (val) {\n\t\tif (arguments.length) {\n\t\t\treturn new Color(val);\n\t\t}\n\n\t\treturn convert[this.model].keyword(this.color);\n\t},\n\n\thex: function (val) {\n\t\tif (arguments.length) {\n\t\t\treturn new Color(val);\n\t\t}\n\n\t\treturn colorString.to.hex(this.rgb().round().color);\n\t},\n\n\trgbNumber: function () {\n\t\tvar rgb = this.rgb().color;\n\t\treturn ((rgb[0] & 0xFF) << 16) | ((rgb[1] & 0xFF) << 8) | (rgb[2] & 0xFF);\n\t},\n\n\tluminosity: function () {\n\t\t// http://www.w3.org/TR/WCAG20/#relativeluminancedef\n\t\tvar rgb = this.rgb().color;\n\n\t\tvar lum = [];\n\t\tfor (var i = 0; i < rgb.length; i++) {\n\t\t\tvar chan = rgb[i] / 255;\n\t\t\tlum[i] = (chan <= 0.03928) ? chan / 12.92 : Math.pow(((chan + 0.055) / 1.055), 2.4);\n\t\t}\n\n\t\treturn 0.2126 * lum[0] + 0.7152 * lum[1] + 0.0722 * lum[2];\n\t},\n\n\tcontrast: function (color2) {\n\t\t// http://www.w3.org/TR/WCAG20/#contrast-ratiodef\n\t\tvar lum1 = this.luminosity();\n\t\tvar lum2 = color2.luminosity();\n\n\t\tif (lum1 > lum2) {\n\t\t\treturn (lum1 + 0.05) / (lum2 + 0.05);\n\t\t}\n\n\t\treturn (lum2 + 0.05) / (lum1 + 0.05);\n\t},\n\n\tlevel: function (color2) {\n\t\tvar contrastRatio = this.contrast(color2);\n\t\tif (contrastRatio >= 7.1) {\n\t\t\treturn 'AAA';\n\t\t}\n\n\t\treturn (contrastRatio >= 4.5) ? 'AA' : '';\n\t},\n\n\tisDark: function () {\n\t\t// YIQ equation from http://24ways.org/2010/calculating-color-contrast\n\t\tvar rgb = this.rgb().color;\n\t\tvar yiq = (rgb[0] * 299 + rgb[1] * 587 + rgb[2] * 114) / 1000;\n\t\treturn yiq < 128;\n\t},\n\n\tisLight: function () {\n\t\treturn !this.isDark();\n\t},\n\n\tnegate: function () {\n\t\tvar rgb = this.rgb();\n\t\tfor (var i = 0; i < 3; i++) {\n\t\t\trgb.color[i] = 255 - rgb.color[i];\n\t\t}\n\t\treturn rgb;\n\t},\n\n\tlighten: function (ratio) {\n\t\tvar hsl = this.hsl();\n\t\thsl.color[2] += hsl.color[2] * ratio;\n\t\treturn hsl;\n\t},\n\n\tdarken: function (ratio) {\n\t\tvar hsl = this.hsl();\n\t\thsl.color[2] -= hsl.color[2] * ratio;\n\t\treturn hsl;\n\t},\n\n\tsaturate: function (ratio) {\n\t\tvar hsl = this.hsl();\n\t\thsl.color[1] += hsl.color[1] * ratio;\n\t\treturn hsl;\n\t},\n\n\tdesaturate: function (ratio) {\n\t\tvar hsl = this.hsl();\n\t\thsl.color[1] -= hsl.color[1] * ratio;\n\t\treturn hsl;\n\t},\n\n\twhiten: function (ratio) {\n\t\tvar hwb = this.hwb();\n\t\thwb.color[1] += hwb.color[1] * ratio;\n\t\treturn hwb;\n\t},\n\n\tblacken: function (ratio) {\n\t\tvar hwb = this.hwb();\n\t\thwb.color[2] += hwb.color[2] * ratio;\n\t\treturn hwb;\n\t},\n\n\tgrayscale: function () {\n\t\t// http://en.wikipedia.org/wiki/Grayscale#Converting_color_to_grayscale\n\t\tvar rgb = this.rgb().color;\n\t\tvar val = rgb[0] * 0.3 + rgb[1] * 0.59 + rgb[2] * 0.11;\n\t\treturn Color.rgb(val, val, val);\n\t},\n\n\tfade: function (ratio) {\n\t\treturn this.alpha(this.valpha - (this.valpha * ratio));\n\t},\n\n\topaquer: function (ratio) {\n\t\treturn this.alpha(this.valpha + (this.valpha * ratio));\n\t},\n\n\trotate: function (degrees) {\n\t\tvar hsl = this.hsl();\n\t\tvar hue = hsl.color[0];\n\t\thue = (hue + degrees) % 360;\n\t\thue = hue < 0 ? 360 + hue : hue;\n\t\thsl.color[0] = hue;\n\t\treturn hsl;\n\t},\n\n\tmix: function (mixinColor, weight) {\n\t\t// ported from sass implementation in C\n\t\t// https://github.com/sass/libsass/blob/0e6b4a2850092356aa3ece07c6b249f0221caced/functions.cpp#L209\n\t\tif (!mixinColor || !mixinColor.rgb) {\n\t\t\tthrow new Error('Argument to \"mix\" was not a Color instance, but rather an instance of ' + typeof mixinColor);\n\t\t}\n\t\tvar color1 = mixinColor.rgb();\n\t\tvar color2 = this.rgb();\n\t\tvar p = weight === undefined ? 0.5 : weight;\n\n\t\tvar w = 2 * p - 1;\n\t\tvar a = color1.alpha() - color2.alpha();\n\n\t\tvar w1 = (((w * a === -1) ? w : (w + a) / (1 + w * a)) + 1) / 2.0;\n\t\tvar w2 = 1 - w1;\n\n\t\treturn Color.rgb(\n\t\t\t\tw1 * color1.red() + w2 * color2.red(),\n\t\t\t\tw1 * color1.green() + w2 * color2.green(),\n\t\t\t\tw1 * color1.blue() + w2 * color2.blue(),\n\t\t\t\tcolor1.alpha() * p + color2.alpha() * (1 - p));\n\t}\n};\n\n// model conversion methods and static constructors\nObject.keys(convert).forEach(function (model) {\n\tif (skippedModels.indexOf(model) !== -1) {\n\t\treturn;\n\t}\n\n\tvar channels = convert[model].channels;\n\n\t// conversion methods\n\tColor.prototype[model] = function () {\n\t\tif (this.model === model) {\n\t\t\treturn new Color(this);\n\t\t}\n\n\t\tif (arguments.length) {\n\t\t\treturn new Color(arguments, model);\n\t\t}\n\n\t\tvar newAlpha = typeof arguments[channels] === 'number' ? channels : this.valpha;\n\t\treturn new Color(assertArray(convert[this.model][model].raw(this.color)).concat(newAlpha), model);\n\t};\n\n\t// 'static' construction methods\n\tColor[model] = function (color) {\n\t\tif (typeof color === 'number') {\n\t\t\tcolor = zeroArray(_slice.call(arguments), channels);\n\t\t}\n\t\treturn new Color(color, model);\n\t};\n});\n\nfunction roundTo(num, places) {\n\treturn Number(num.toFixed(places));\n}\n\nfunction roundToPlace(places) {\n\treturn function (num) {\n\t\treturn roundTo(num, places);\n\t};\n}\n\nfunction getset(model, channel, modifier) {\n\tmodel = Array.isArray(model) ? model : [model];\n\n\tmodel.forEach(function (m) {\n\t\t(limiters[m] || (limiters[m] = []))[channel] = modifier;\n\t});\n\n\tmodel = model[0];\n\n\treturn function (val) {\n\t\tvar result;\n\n\t\tif (arguments.length) {\n\t\t\tif (modifier) {\n\t\t\t\tval = modifier(val);\n\t\t\t}\n\n\t\t\tresult = this[model]();\n\t\t\tresult.color[channel] = val;\n\t\t\treturn result;\n\t\t}\n\n\t\tresult = this[model]().color[channel];\n\t\tif (modifier) {\n\t\t\tresult = modifier(result);\n\t\t}\n\n\t\treturn result;\n\t};\n}\n\nfunction maxfn(max) {\n\treturn function (v) {\n\t\treturn Math.max(0, Math.min(max, v));\n\t};\n}\n\nfunction assertArray(val) {\n\treturn Array.isArray(val) ? val : [val];\n}\n\nfunction zeroArray(arr, length) {\n\tfor (var i = 0; i < length; i++) {\n\t\tif (typeof arr[i] !== 'number') {\n\t\t\tarr[i] = 0;\n\t\t}\n\t}\n\n\treturn arr;\n}\n\nmodule.exports = Color;\n\n\n//# sourceURL=webpack:///./node_modules/color/index.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/css-loader/dist/cjs.js!./node_modules/sass-loader/dist/cjs.js?!./src/gui/component/audio-node.scss":
|
|
/*!**********************************************************************************************************************************!*\
|
|
!*** ./node_modules/css-loader/dist/cjs.js!./node_modules/sass-loader/dist/cjs.js??ref--5-2!./src/gui/component/audio-node.scss ***!
|
|
\**********************************************************************************************************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
eval("// Imports\nvar ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../node_modules/css-loader/dist/runtime/api.js */ \"./node_modules/css-loader/dist/runtime/api.js\");\nexports = ___CSS_LOADER_API_IMPORT___(false);\n// Module\nexports.push([module.i, \":host {\\n max-width: 320px;\\n width: 100%;\\n display: block; }\\n\\n#container {\\n font-family: \\\"Open Sans\\\", sans-serif;\\n margin-bottom: 10px;\\n border-bottom: 1px solid #ddd;\\n max-width: 320px;\\n width: 100%; }\\n #container #title {\\n font-size: 18px !important;\\n font-family: \\\"Roboto\\\", sans-serif; }\\n #container .value {\\n display: block;\\n margin-top: 4px; }\\n #container details {\\n margin-top: 4px;\\n font-size: 14px;\\n line-height: 24px; }\\n #container details.sub-value {\\n background-color: rgba(0, 0, 0, 0.05);\\n padding: 5px; }\\n #container details #json {\\n font-size: 0.8em; }\\n #container details #json summary {\\n color: #f5871f;\\n padding-left: 10px; }\\n #container details #json summary mwc-icon {\\n --mdc-icon-size: 10px; }\\n #container details #json pre {\\n overflow: scroll; }\\n #container details summary {\\n list-style: none; }\\n #container details summary mwc-icon {\\n position: relative;\\n transform: translate(0px, 4px);\\n height: 20px;\\n font-size: 20px;\\n margin-left: 0px; }\\n #container details summary #download {\\n position: absolute;\\n right: 10px;\\n color: #ececec; }\\n #container details summary#title {\\n padding: 2px 2px 5px 2px; }\\n #container details summary::-webkit-details-marker {\\n display: none; }\\n #container details summary::marker {\\n display: none; }\\n #container details summary:focus {\\n outline: none;\\n background-color: #fcd5b1; }\\n\", \"\"]);\n// Exports\nmodule.exports = exports;\n\n\n//# sourceURL=webpack:///./src/gui/component/audio-node.scss?./node_modules/css-loader/dist/cjs.js!./node_modules/sass-loader/dist/cjs.js??ref--5-2");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/css-loader/dist/cjs.js!./node_modules/sass-loader/dist/cjs.js?!./src/gui/component/drawer.scss":
|
|
/*!******************************************************************************************************************************!*\
|
|
!*** ./node_modules/css-loader/dist/cjs.js!./node_modules/sass-loader/dist/cjs.js??ref--5-2!./src/gui/component/drawer.scss ***!
|
|
\******************************************************************************************************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
eval("// Imports\nvar ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../node_modules/css-loader/dist/runtime/api.js */ \"./node_modules/css-loader/dist/runtime/api.js\");\nexports = ___CSS_LOADER_API_IMPORT___(false);\n// Module\nexports.push([module.i, \"#container {\\n display: inline-block;\\n position: fixed;\\n right: 0px;\\n bottom: 0px;\\n width: 320px;\\n background-color: white;\\n z-index: 1000000;\\n box-shadow: 0 3px 6px rgba(0, 0, 0, 0.16), 0 3px 6px rgba(0, 0, 0, 0.23); }\\n #container[hidden] {\\n display: none; }\\n #container:not([open]) {\\n height: 20px; }\\n #container #scroll {\\n display: inline-block;\\n max-height: calc( 100vh - 24px - 20px);\\n margin-top: 20px;\\n width: calc(100% - 20px);\\n overflow-y: auto;\\n padding: 10px;\\n padding-bottom: 0px; }\\n #container #scroll #inner-scroll {\\n display: inline-block;\\n width: 100%; }\\n #container details summary {\\n background-color: #ececec;\\n color: #616161;\\n text-align: center;\\n font-family: \\\"Roboto\\\", sans-serif;\\n text-align: center;\\n position: absolute;\\n top: 3px;\\n width: calc(100% - 6px);\\n left: 3px;\\n font-size: 0.8em;\\n height: 14px;\\n line-height: 14px;\\n border-radius: 3px;\\n cursor: pointer;\\n list-style: none; }\\n #container details summary mwc-icon {\\n position: absolute;\\n top: 0px;\\n left: 0px;\\n height: 14px;\\n font-size: 14px; }\\n #container details summary::-webkit-details-marker {\\n display: none; }\\n #container details summary::marker {\\n display: none; }\\n\", \"\"]);\n// Exports\nmodule.exports = exports;\n\n\n//# sourceURL=webpack:///./src/gui/component/drawer.scss?./node_modules/css-loader/dist/cjs.js!./node_modules/sass-loader/dist/cjs.js??ref--5-2");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/css-loader/dist/cjs.js!./node_modules/sass-loader/dist/cjs.js?!./src/gui/component/folder.scss":
|
|
/*!******************************************************************************************************************************!*\
|
|
!*** ./node_modules/css-loader/dist/cjs.js!./node_modules/sass-loader/dist/cjs.js??ref--5-2!./src/gui/component/folder.scss ***!
|
|
\******************************************************************************************************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
eval("// Imports\nvar ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../node_modules/css-loader/dist/runtime/api.js */ \"./node_modules/css-loader/dist/runtime/api.js\");\nexports = ___CSS_LOADER_API_IMPORT___(false);\n// Module\nexports.push([module.i, \"#container {\\n font-family: \\\"Roboto\\\", sans-serif;\\n width: calc(100% - 20px);\\n margin-bottom: 10px; }\\n #container details {\\n width: 100%; }\\n #container details summary {\\n font-weight: bold;\\n font-size: 1.1em;\\n border-bottom: 1px solid black;\\n list-style: none; }\\n #container details summary mwc-icon {\\n position: relative;\\n transform: translate(0px, 4px);\\n height: 20px;\\n font-size: 20px;\\n margin-left: 0px; }\\n #container details summary::-webkit-details-marker {\\n display: none; }\\n #container details summary::marker {\\n display: none; }\\n #container details #contents {\\n width: calc(100% - 5px);\\n margin-left: 5px; }\\n\", \"\"]);\n// Exports\nmodule.exports = exports;\n\n\n//# sourceURL=webpack:///./src/gui/component/folder.scss?./node_modules/css-loader/dist/cjs.js!./node_modules/sass-loader/dist/cjs.js??ref--5-2");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/css-loader/dist/cjs.js!./node_modules/sass-loader/dist/cjs.js?!./src/gui/value/value.scss":
|
|
/*!*************************************************************************************************************************!*\
|
|
!*** ./node_modules/css-loader/dist/cjs.js!./node_modules/sass-loader/dist/cjs.js??ref--5-2!./src/gui/value/value.scss ***!
|
|
\*************************************************************************************************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
eval("// Imports\nvar ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../node_modules/css-loader/dist/runtime/api.js */ \"./node_modules/css-loader/dist/runtime/api.js\");\nexports = ___CSS_LOADER_API_IMPORT___(false);\n// Module\nexports.push([module.i, \"#container {\\n width: 100%;\\n font-size: 14px;\\n font-family: \\\"Open Sans\\\", sans-serif;\\n background-color: transparent; }\\n #container label {\\n padding-left: 6px; }\\n #container.error input {\\n transition-duration: 0s;\\n color: gray; }\\n #container input {\\n transition: color 0.2s;\\n font-family: inherit;\\n font-size: inherit;\\n -webkit-appearance: none;\\n appearance: none;\\n border: 0px;\\n text-align: right;\\n float: right;\\n background-color: transparent;\\n outline: 0px solid #fcd5b1; }\\n #container input:focus {\\n outline-width: 3px; }\\n #container.array {\\n display: flex; }\\n #container.array label, #container.array #bars {\\n flex: 1; }\\n #container.array label[disabled] {\\n color: lightgray; }\\n #container.array #bars {\\n display: flex;\\n flex-direction: row; }\\n #container.array #bars .bar {\\n flex: 1;\\n height: 100%;\\n position: relative;\\n margin: 0px 1px; }\\n #container.array #bars .bar .fill {\\n pointer-events: none;\\n background-color: black;\\n position: absolute;\\n bottom: 0px;\\n left: 0px;\\n width: 100%;\\n height: 0px; }\\n #container.boolean input {\\n margin: 0px;\\n box-sizing: border-box;\\n border: 2px solid #ddd;\\n background-color: #ddd;\\n width: 16px;\\n height: 16px; }\\n #container.boolean input[checked] {\\n background-color: black; }\\n\", \"\"]);\n// Exports\nmodule.exports = exports;\n\n\n//# sourceURL=webpack:///./src/gui/value/value.scss?./node_modules/css-loader/dist/cjs.js!./node_modules/sass-loader/dist/cjs.js??ref--5-2");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/css-loader/dist/runtime/api.js":
|
|
/*!*****************************************************!*\
|
|
!*** ./node_modules/css-loader/dist/runtime/api.js ***!
|
|
\*****************************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\n/*\n MIT License http://www.opensource.org/licenses/mit-license.php\n Author Tobias Koppers @sokra\n*/\n// css base code, injected by the css-loader\n// eslint-disable-next-line func-names\nmodule.exports = function (useSourceMap) {\n var list = []; // return the list of modules as css string\n\n list.toString = function toString() {\n return this.map(function (item) {\n var content = cssWithMappingToString(item, useSourceMap);\n\n if (item[2]) {\n return \"@media \".concat(item[2], \" {\").concat(content, \"}\");\n }\n\n return content;\n }).join('');\n }; // import a list of modules into the list\n // eslint-disable-next-line func-names\n\n\n list.i = function (modules, mediaQuery, dedupe) {\n if (typeof modules === 'string') {\n // eslint-disable-next-line no-param-reassign\n modules = [[null, modules, '']];\n }\n\n var alreadyImportedModules = {};\n\n if (dedupe) {\n for (var i = 0; i < this.length; i++) {\n // eslint-disable-next-line prefer-destructuring\n var id = this[i][0];\n\n if (id != null) {\n alreadyImportedModules[id] = true;\n }\n }\n }\n\n for (var _i = 0; _i < modules.length; _i++) {\n var item = [].concat(modules[_i]);\n\n if (dedupe && alreadyImportedModules[item[0]]) {\n // eslint-disable-next-line no-continue\n continue;\n }\n\n if (mediaQuery) {\n if (!item[2]) {\n item[2] = mediaQuery;\n } else {\n item[2] = \"\".concat(mediaQuery, \" and \").concat(item[2]);\n }\n }\n\n list.push(item);\n }\n };\n\n return list;\n};\n\nfunction cssWithMappingToString(item, useSourceMap) {\n var content = item[1] || ''; // eslint-disable-next-line prefer-destructuring\n\n var cssMapping = item[3];\n\n if (!cssMapping) {\n return content;\n }\n\n if (useSourceMap && typeof btoa === 'function') {\n var sourceMapping = toComment(cssMapping);\n var sourceURLs = cssMapping.sources.map(function (source) {\n return \"/*# sourceURL=\".concat(cssMapping.sourceRoot || '').concat(source, \" */\");\n });\n return [content].concat(sourceURLs).concat([sourceMapping]).join('\\n');\n }\n\n return [content].join('\\n');\n} // Adapted from convert-source-map (MIT)\n\n\nfunction toComment(sourceMap) {\n // eslint-disable-next-line no-undef\n var base64 = btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap))));\n var data = \"sourceMappingURL=data:application/json;charset=utf-8;base64,\".concat(base64);\n return \"/*# \".concat(data, \" */\");\n}\n\n//# sourceURL=webpack:///./node_modules/css-loader/dist/runtime/api.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/deep-equal/index.js":
|
|
/*!******************************************!*\
|
|
!*** ./node_modules/deep-equal/index.js ***!
|
|
\******************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\nvar objectKeys = __webpack_require__(/*! object-keys */ \"./node_modules/object-keys/index.js\");\nvar isArguments = __webpack_require__(/*! is-arguments */ \"./node_modules/is-arguments/index.js\");\nvar is = __webpack_require__(/*! object-is */ \"./node_modules/object-is/index.js\");\nvar isRegex = __webpack_require__(/*! is-regex */ \"./node_modules/is-regex/index.js\");\nvar flags = __webpack_require__(/*! regexp.prototype.flags */ \"./node_modules/regexp.prototype.flags/index.js\");\nvar isArray = __webpack_require__(/*! isarray */ \"./node_modules/deep-equal/node_modules/isarray/index.js\");\nvar isDate = __webpack_require__(/*! is-date-object */ \"./node_modules/is-date-object/index.js\");\nvar whichBoxedPrimitive = __webpack_require__(/*! which-boxed-primitive */ \"./node_modules/which-boxed-primitive/index.js\");\nvar GetIntrinsic = __webpack_require__(/*! es-abstract/GetIntrinsic */ \"./node_modules/es-abstract/GetIntrinsic.js\");\nvar callBound = __webpack_require__(/*! es-abstract/helpers/callBound */ \"./node_modules/es-abstract/helpers/callBound.js\");\nvar whichCollection = __webpack_require__(/*! which-collection */ \"./node_modules/which-collection/index.js\");\nvar getIterator = __webpack_require__(/*! es-get-iterator */ \"./node_modules/es-get-iterator/index.js\");\nvar getSideChannel = __webpack_require__(/*! side-channel */ \"./node_modules/side-channel/index.js\");\nvar whichTypedArray = __webpack_require__(/*! which-typed-array */ \"./node_modules/which-typed-array/index.js\");\nvar assign = __webpack_require__(/*! object.assign */ \"./node_modules/object.assign/index.js\");\n\nvar $getTime = callBound('Date.prototype.getTime');\nvar gPO = Object.getPrototypeOf;\nvar $objToString = callBound('Object.prototype.toString');\n\nvar $Set = GetIntrinsic('%Set%', true);\nvar $mapHas = callBound('Map.prototype.has', true);\nvar $mapGet = callBound('Map.prototype.get', true);\nvar $mapSize = callBound('Map.prototype.size', true);\nvar $setAdd = callBound('Set.prototype.add', true);\nvar $setDelete = callBound('Set.prototype.delete', true);\nvar $setHas = callBound('Set.prototype.has', true);\nvar $setSize = callBound('Set.prototype.size', true);\n\n// taken from https://github.com/browserify/commonjs-assert/blob/bba838e9ba9e28edf3127ce6974624208502f6bc/internal/util/comparisons.js#L401-L414\nfunction setHasEqualElement(set, val1, opts, channel) {\n var i = getIterator(set);\n var result;\n while ((result = i.next()) && !result.done) {\n if (internalDeepEqual(val1, result.value, opts, channel)) { // eslint-disable-line no-use-before-define\n // Remove the matching element to make sure we do not check that again.\n $setDelete(set, result.value);\n return true;\n }\n }\n\n return false;\n}\n\n// taken from https://github.com/browserify/commonjs-assert/blob/bba838e9ba9e28edf3127ce6974624208502f6bc/internal/util/comparisons.js#L416-L439\nfunction findLooseMatchingPrimitives(prim) {\n if (typeof prim === 'undefined') {\n return null;\n }\n if (typeof prim === 'object') { // Only pass in null as object!\n return void 0;\n }\n if (typeof prim === 'symbol') {\n return false;\n }\n if (typeof prim === 'string' || typeof prim === 'number') {\n // Loose equal entries exist only if the string is possible to convert to a regular number and not NaN.\n return +prim === +prim; // eslint-disable-line no-implicit-coercion\n }\n return true;\n}\n\n// taken from https://github.com/browserify/commonjs-assert/blob/bba838e9ba9e28edf3127ce6974624208502f6bc/internal/util/comparisons.js#L449-L460\nfunction mapMightHaveLoosePrim(a, b, prim, item, opts, channel) {\n var altValue = findLooseMatchingPrimitives(prim);\n if (altValue != null) {\n return altValue;\n }\n var curB = $mapGet(b, altValue);\n var looseOpts = assign({}, opts, { strict: false });\n if (\n (typeof curB === 'undefined' && !$mapHas(b, altValue))\n // eslint-disable-next-line no-use-before-define\n || !internalDeepEqual(item, curB, looseOpts, channel)\n ) {\n return false;\n }\n // eslint-disable-next-line no-use-before-define\n return !$mapHas(a, altValue) && internalDeepEqual(item, curB, looseOpts, channel);\n}\n\n// taken from https://github.com/browserify/commonjs-assert/blob/bba838e9ba9e28edf3127ce6974624208502f6bc/internal/util/comparisons.js#L441-L447\nfunction setMightHaveLoosePrim(a, b, prim) {\n var altValue = findLooseMatchingPrimitives(prim);\n if (altValue != null) {\n return altValue;\n }\n\n return $setHas(b, altValue) && !$setHas(a, altValue);\n}\n\n// taken from https://github.com/browserify/commonjs-assert/blob/bba838e9ba9e28edf3127ce6974624208502f6bc/internal/util/comparisons.js#L518-L533\nfunction mapHasEqualEntry(set, map, key1, item1, opts, channel) {\n var i = getIterator(set);\n var result;\n var key2;\n while ((result = i.next()) && !result.done) {\n key2 = result.value;\n if (\n // eslint-disable-next-line no-use-before-define\n internalDeepEqual(key1, key2, opts, channel)\n // eslint-disable-next-line no-use-before-define\n && internalDeepEqual(item1, $mapGet(map, key2), opts, channel)\n ) {\n $setDelete(set, key2);\n return true;\n }\n }\n\n return false;\n}\n\nfunction internalDeepEqual(actual, expected, options, channel) {\n var opts = options || {};\n\n // 7.1. All identical values are equivalent, as determined by ===.\n if (opts.strict ? is(actual, expected) : actual === expected) {\n return true;\n }\n\n var actualBoxed = whichBoxedPrimitive(actual);\n var expectedBoxed = whichBoxedPrimitive(expected);\n if (actualBoxed !== expectedBoxed) {\n return false;\n }\n\n // 7.3. Other pairs that do not both pass typeof value == 'object', equivalence is determined by ==.\n if (!actual || !expected || (typeof actual !== 'object' && typeof expected !== 'object')) {\n return opts.strict ? is(actual, expected) : actual == expected; // eslint-disable-line eqeqeq\n }\n\n /*\n * 7.4. For all other Object pairs, including Array objects, equivalence is\n * determined by having the same number of owned properties (as verified\n * with Object.prototype.hasOwnProperty.call), the same set of keys\n * (although not necessarily the same order), equivalent values for every\n * corresponding key, and an identical 'prototype' property. Note: this\n * accounts for both named and indexed properties on Arrays.\n */\n // see https://github.com/nodejs/node/commit/d3aafd02efd3a403d646a3044adcf14e63a88d32 for memos/channel inspiration\n\n var hasActual = channel.has(actual);\n var hasExpected = channel.has(expected);\n var sentinel;\n if (hasActual && hasExpected) {\n if (channel.get(actual) === channel.get(expected)) {\n return true;\n }\n } else {\n sentinel = {};\n }\n if (!hasActual) { channel.set(actual, sentinel); }\n if (!hasExpected) { channel.set(expected, sentinel); }\n\n // eslint-disable-next-line no-use-before-define\n return objEquiv(actual, expected, opts, channel);\n}\n\nfunction isBuffer(x) {\n if (!x || typeof x !== 'object' || typeof x.length !== 'number') {\n return false;\n }\n if (typeof x.copy !== 'function' || typeof x.slice !== 'function') {\n return false;\n }\n if (x.length > 0 && typeof x[0] !== 'number') {\n return false;\n }\n\n return !!(x.constructor && x.constructor.isBuffer && x.constructor.isBuffer(x));\n}\n\nfunction setEquiv(a, b, opts, channel) {\n if ($setSize(a) !== $setSize(b)) {\n return false;\n }\n var iA = getIterator(a);\n var iB = getIterator(b);\n var resultA;\n var resultB;\n var set;\n while ((resultA = iA.next()) && !resultA.done) {\n if (resultA.value && typeof resultA.value === 'object') {\n if (!set) { set = new $Set(); }\n $setAdd(set, resultA.value);\n } else if (!$setHas(b, resultA.value)) {\n if (opts.strict) { return false; }\n if (!setMightHaveLoosePrim(a, b, resultA.value)) {\n return false;\n }\n if (!set) { set = new $Set(); }\n $setAdd(set, resultA.value);\n }\n }\n if (set) {\n while ((resultB = iB.next()) && !resultB.done) {\n // We have to check if a primitive value is already matching and only if it's not, go hunting for it.\n if (resultB.value && typeof resultB.value === 'object') {\n if (!setHasEqualElement(set, resultB.value, opts.strict, channel)) {\n return false;\n }\n } else if (\n !opts.strict\n && !$setHas(a, resultB.value)\n && !setHasEqualElement(set, resultB.value, opts.strict, channel)\n ) {\n return false;\n }\n }\n return $setSize(set) === 0;\n }\n return true;\n}\n\nfunction mapEquiv(a, b, opts, channel) {\n if ($mapSize(a) !== $mapSize(b)) {\n return false;\n }\n var iA = getIterator(a);\n var iB = getIterator(b);\n var resultA;\n var resultB;\n var set;\n var key;\n var item1;\n var item2;\n while ((resultA = iA.next()) && !resultA.done) {\n key = resultA.value[0];\n item1 = resultA.value[1];\n if (key && typeof key === 'object') {\n if (!set) { set = new $Set(); }\n $setAdd(set, key);\n } else {\n item2 = $mapGet(b, key);\n if ((typeof item2 === 'undefined' && !$mapHas(b, key)) || !internalDeepEqual(item1, item2, opts, channel)) {\n if (opts.strict) {\n return false;\n }\n if (!mapMightHaveLoosePrim(a, b, key, item1, opts, channel)) {\n return false;\n }\n if (!set) { set = new $Set(); }\n $setAdd(set, key);\n }\n }\n }\n\n if (set) {\n while ((resultB = iB.next()) && !resultB.done) {\n key = resultB.value[0];\n item2 = resultB.value[1];\n if (key && typeof key === 'object') {\n if (!mapHasEqualEntry(set, a, key, item2, opts, channel)) {\n return false;\n }\n } else if (\n !opts.strict\n && (!a.has(key) || !internalDeepEqual($mapGet(a, key), item2, opts, channel))\n && !mapHasEqualEntry(set, a, key, item2, assign({}, opts, { strict: false }), channel)\n ) {\n return false;\n }\n }\n return $setSize(set) === 0;\n }\n return true;\n}\n\nfunction objEquiv(a, b, opts, channel) {\n /* eslint max-statements: [2, 100], max-lines-per-function: [2, 120], max-depth: [2, 5] */\n var i, key;\n\n if (typeof a !== typeof b) { return false; }\n if (a == null || b == null) { return false; }\n\n if ($objToString(a) !== $objToString(b)) { return false; }\n\n if (isArguments(a) !== isArguments(b)) { return false; }\n\n var aIsArray = isArray(a);\n var bIsArray = isArray(b);\n if (aIsArray !== bIsArray) { return false; }\n\n // TODO: replace when a cross-realm brand check is available\n var aIsError = a instanceof Error;\n var bIsError = b instanceof Error;\n if (aIsError !== bIsError) { return false; }\n if (aIsError || bIsError) {\n if (a.name !== b.name || a.message !== b.message) { return false; }\n }\n\n var aIsRegex = isRegex(a);\n var bIsRegex = isRegex(b);\n if (aIsRegex !== bIsRegex) { return false; }\n if ((aIsRegex || bIsRegex) && (a.source !== b.source || flags(a) !== flags(b))) {\n return false;\n }\n\n var aIsDate = isDate(a);\n var bIsDate = isDate(b);\n if (aIsDate !== bIsDate) { return false; }\n if (aIsDate || bIsDate) { // && would work too, because both are true or both false here\n if ($getTime(a) !== $getTime(b)) { return false; }\n }\n if (opts.strict && gPO && gPO(a) !== gPO(b)) { return false; }\n\n if (whichTypedArray(a) !== whichTypedArray(b)) {\n return false;\n }\n\n var aIsBuffer = isBuffer(a);\n var bIsBuffer = isBuffer(b);\n if (aIsBuffer !== bIsBuffer) { return false; }\n if (aIsBuffer || bIsBuffer) { // && would work too, because both are true or both false here\n if (a.length !== b.length) { return false; }\n for (i = 0; i < a.length; i++) {\n if (a[i] !== b[i]) { return false; }\n }\n return true;\n }\n\n if (typeof a !== typeof b) { return false; }\n\n var ka = objectKeys(a);\n var kb = objectKeys(b);\n // having the same number of owned properties (keys incorporates hasOwnProperty)\n if (ka.length !== kb.length) { return false; }\n\n // the same set of keys (although not necessarily the same order),\n ka.sort();\n kb.sort();\n // ~~~cheap key test\n for (i = ka.length - 1; i >= 0; i--) {\n if (ka[i] != kb[i]) { return false; } // eslint-disable-line eqeqeq\n }\n\n // equivalent values for every corresponding key, and ~~~possibly expensive deep test\n for (i = ka.length - 1; i >= 0; i--) {\n key = ka[i];\n if (!internalDeepEqual(a[key], b[key], opts, channel)) { return false; }\n }\n\n var aCollection = whichCollection(a);\n var bCollection = whichCollection(b);\n if (aCollection !== bCollection) {\n return false;\n }\n if (aCollection === 'Set' || bCollection === 'Set') { // aCollection === bCollection\n return setEquiv(a, b, opts, channel);\n }\n if (aCollection === 'Map') { // aCollection === bCollection\n return mapEquiv(a, b, opts, channel);\n }\n\n return true;\n}\n\nmodule.exports = function deepEqual(a, b, opts) {\n return internalDeepEqual(a, b, opts, getSideChannel());\n};\n\n\n//# sourceURL=webpack:///./node_modules/deep-equal/index.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/deep-equal/node_modules/isarray/index.js":
|
|
/*!***************************************************************!*\
|
|
!*** ./node_modules/deep-equal/node_modules/isarray/index.js ***!
|
|
\***************************************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports) {
|
|
|
|
eval("var toString = {}.toString;\n\nmodule.exports = Array.isArray || function (arr) {\n return toString.call(arr) == '[object Array]';\n};\n\n\n//# sourceURL=webpack:///./node_modules/deep-equal/node_modules/isarray/index.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/define-properties/index.js":
|
|
/*!*************************************************!*\
|
|
!*** ./node_modules/define-properties/index.js ***!
|
|
\*************************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\nvar keys = __webpack_require__(/*! object-keys */ \"./node_modules/object-keys/index.js\");\nvar hasSymbols = typeof Symbol === 'function' && typeof Symbol('foo') === 'symbol';\n\nvar toStr = Object.prototype.toString;\nvar concat = Array.prototype.concat;\nvar origDefineProperty = Object.defineProperty;\n\nvar isFunction = function (fn) {\n\treturn typeof fn === 'function' && toStr.call(fn) === '[object Function]';\n};\n\nvar arePropertyDescriptorsSupported = function () {\n\tvar obj = {};\n\ttry {\n\t\torigDefineProperty(obj, 'x', { enumerable: false, value: obj });\n\t\t// eslint-disable-next-line no-unused-vars, no-restricted-syntax\n\t\tfor (var _ in obj) { // jscs:ignore disallowUnusedVariables\n\t\t\treturn false;\n\t\t}\n\t\treturn obj.x === obj;\n\t} catch (e) { /* this is IE 8. */\n\t\treturn false;\n\t}\n};\nvar supportsDescriptors = origDefineProperty && arePropertyDescriptorsSupported();\n\nvar defineProperty = function (object, name, value, predicate) {\n\tif (name in object && (!isFunction(predicate) || !predicate())) {\n\t\treturn;\n\t}\n\tif (supportsDescriptors) {\n\t\torigDefineProperty(object, name, {\n\t\t\tconfigurable: true,\n\t\t\tenumerable: false,\n\t\t\tvalue: value,\n\t\t\twritable: true\n\t\t});\n\t} else {\n\t\tobject[name] = value;\n\t}\n};\n\nvar defineProperties = function (object, map) {\n\tvar predicates = arguments.length > 2 ? arguments[2] : {};\n\tvar props = keys(map);\n\tif (hasSymbols) {\n\t\tprops = concat.call(props, Object.getOwnPropertySymbols(map));\n\t}\n\tfor (var i = 0; i < props.length; i += 1) {\n\t\tdefineProperty(object, props[i], map[props[i]], predicates[props[i]]);\n\t}\n};\n\ndefineProperties.supportsDescriptors = !!supportsDescriptors;\n\nmodule.exports = defineProperties;\n\n\n//# sourceURL=webpack:///./node_modules/define-properties/index.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/es-abstract/GetIntrinsic.js":
|
|
/*!**************************************************!*\
|
|
!*** ./node_modules/es-abstract/GetIntrinsic.js ***!
|
|
\**************************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\n/* globals\n\tAtomics,\n\tSharedArrayBuffer,\n*/\n\nvar undefined;\n\nvar $TypeError = TypeError;\n\nvar $gOPD = Object.getOwnPropertyDescriptor;\nif ($gOPD) {\n\ttry {\n\t\t$gOPD({}, '');\n\t} catch (e) {\n\t\t$gOPD = null; // this is IE 8, which has a broken gOPD\n\t}\n}\n\nvar throwTypeError = function () { throw new $TypeError(); };\nvar ThrowTypeError = $gOPD\n\t? (function () {\n\t\ttry {\n\t\t\t// eslint-disable-next-line no-unused-expressions, no-caller, no-restricted-properties\n\t\t\targuments.callee; // IE 8 does not throw here\n\t\t\treturn throwTypeError;\n\t\t} catch (calleeThrows) {\n\t\t\ttry {\n\t\t\t\t// IE 8 throws on Object.getOwnPropertyDescriptor(arguments, '')\n\t\t\t\treturn $gOPD(arguments, 'callee').get;\n\t\t\t} catch (gOPDthrows) {\n\t\t\t\treturn throwTypeError;\n\t\t\t}\n\t\t}\n\t}())\n\t: throwTypeError;\n\nvar hasSymbols = __webpack_require__(/*! has-symbols */ \"./node_modules/has-symbols/index.js\")();\n\nvar getProto = Object.getPrototypeOf || function (x) { return x.__proto__; }; // eslint-disable-line no-proto\n\nvar generator; // = function * () {};\nvar generatorFunction = generator ? getProto(generator) : undefined;\nvar asyncFn; // async function() {};\nvar asyncFunction = asyncFn ? asyncFn.constructor : undefined;\nvar asyncGen; // async function * () {};\nvar asyncGenFunction = asyncGen ? getProto(asyncGen) : undefined;\nvar asyncGenIterator = asyncGen ? asyncGen() : undefined;\n\nvar TypedArray = typeof Uint8Array === 'undefined' ? undefined : getProto(Uint8Array);\n\nvar INTRINSICS = {\n\t'%Array%': Array,\n\t'%ArrayBuffer%': typeof ArrayBuffer === 'undefined' ? undefined : ArrayBuffer,\n\t'%ArrayBufferPrototype%': typeof ArrayBuffer === 'undefined' ? undefined : ArrayBuffer.prototype,\n\t'%ArrayIteratorPrototype%': hasSymbols ? getProto([][Symbol.iterator]()) : undefined,\n\t'%ArrayPrototype%': Array.prototype,\n\t'%ArrayProto_entries%': Array.prototype.entries,\n\t'%ArrayProto_forEach%': Array.prototype.forEach,\n\t'%ArrayProto_keys%': Array.prototype.keys,\n\t'%ArrayProto_values%': Array.prototype.values,\n\t'%AsyncFromSyncIteratorPrototype%': undefined,\n\t'%AsyncFunction%': asyncFunction,\n\t'%AsyncFunctionPrototype%': asyncFunction ? asyncFunction.prototype : undefined,\n\t'%AsyncGenerator%': asyncGen ? getProto(asyncGenIterator) : undefined,\n\t'%AsyncGeneratorFunction%': asyncGenFunction,\n\t'%AsyncGeneratorPrototype%': asyncGenFunction ? asyncGenFunction.prototype : undefined,\n\t'%AsyncIteratorPrototype%': asyncGenIterator && hasSymbols && Symbol.asyncIterator ? asyncGenIterator[Symbol.asyncIterator]() : undefined,\n\t'%Atomics%': typeof Atomics === 'undefined' ? undefined : Atomics,\n\t'%Boolean%': Boolean,\n\t'%BooleanPrototype%': Boolean.prototype,\n\t'%DataView%': typeof DataView === 'undefined' ? undefined : DataView,\n\t'%DataViewPrototype%': typeof DataView === 'undefined' ? undefined : DataView.prototype,\n\t'%Date%': Date,\n\t'%DatePrototype%': Date.prototype,\n\t'%decodeURI%': decodeURI,\n\t'%decodeURIComponent%': decodeURIComponent,\n\t'%encodeURI%': encodeURI,\n\t'%encodeURIComponent%': encodeURIComponent,\n\t'%Error%': Error,\n\t'%ErrorPrototype%': Error.prototype,\n\t'%eval%': eval, // eslint-disable-line no-eval\n\t'%EvalError%': EvalError,\n\t'%EvalErrorPrototype%': EvalError.prototype,\n\t'%Float32Array%': typeof Float32Array === 'undefined' ? undefined : Float32Array,\n\t'%Float32ArrayPrototype%': typeof Float32Array === 'undefined' ? undefined : Float32Array.prototype,\n\t'%Float64Array%': typeof Float64Array === 'undefined' ? undefined : Float64Array,\n\t'%Float64ArrayPrototype%': typeof Float64Array === 'undefined' ? undefined : Float64Array.prototype,\n\t'%Function%': Function,\n\t'%FunctionPrototype%': Function.prototype,\n\t'%Generator%': generator ? getProto(generator()) : undefined,\n\t'%GeneratorFunction%': generatorFunction,\n\t'%GeneratorPrototype%': generatorFunction ? generatorFunction.prototype : undefined,\n\t'%Int8Array%': typeof Int8Array === 'undefined' ? undefined : Int8Array,\n\t'%Int8ArrayPrototype%': typeof Int8Array === 'undefined' ? undefined : Int8Array.prototype,\n\t'%Int16Array%': typeof Int16Array === 'undefined' ? undefined : Int16Array,\n\t'%Int16ArrayPrototype%': typeof Int16Array === 'undefined' ? undefined : Int8Array.prototype,\n\t'%Int32Array%': typeof Int32Array === 'undefined' ? undefined : Int32Array,\n\t'%Int32ArrayPrototype%': typeof Int32Array === 'undefined' ? undefined : Int32Array.prototype,\n\t'%isFinite%': isFinite,\n\t'%isNaN%': isNaN,\n\t'%IteratorPrototype%': hasSymbols ? getProto(getProto([][Symbol.iterator]())) : undefined,\n\t'%JSON%': typeof JSON === 'object' ? JSON : undefined,\n\t'%JSONParse%': typeof JSON === 'object' ? JSON.parse : undefined,\n\t'%Map%': typeof Map === 'undefined' ? undefined : Map,\n\t'%MapIteratorPrototype%': typeof Map === 'undefined' || !hasSymbols ? undefined : getProto(new Map()[Symbol.iterator]()),\n\t'%MapPrototype%': typeof Map === 'undefined' ? undefined : Map.prototype,\n\t'%Math%': Math,\n\t'%Number%': Number,\n\t'%NumberPrototype%': Number.prototype,\n\t'%Object%': Object,\n\t'%ObjectPrototype%': Object.prototype,\n\t'%ObjProto_toString%': Object.prototype.toString,\n\t'%ObjProto_valueOf%': Object.prototype.valueOf,\n\t'%parseFloat%': parseFloat,\n\t'%parseInt%': parseInt,\n\t'%Promise%': typeof Promise === 'undefined' ? undefined : Promise,\n\t'%PromisePrototype%': typeof Promise === 'undefined' ? undefined : Promise.prototype,\n\t'%PromiseProto_then%': typeof Promise === 'undefined' ? undefined : Promise.prototype.then,\n\t'%Promise_all%': typeof Promise === 'undefined' ? undefined : Promise.all,\n\t'%Promise_reject%': typeof Promise === 'undefined' ? undefined : Promise.reject,\n\t'%Promise_resolve%': typeof Promise === 'undefined' ? undefined : Promise.resolve,\n\t'%Proxy%': typeof Proxy === 'undefined' ? undefined : Proxy,\n\t'%RangeError%': RangeError,\n\t'%RangeErrorPrototype%': RangeError.prototype,\n\t'%ReferenceError%': ReferenceError,\n\t'%ReferenceErrorPrototype%': ReferenceError.prototype,\n\t'%Reflect%': typeof Reflect === 'undefined' ? undefined : Reflect,\n\t'%RegExp%': RegExp,\n\t'%RegExpPrototype%': RegExp.prototype,\n\t'%Set%': typeof Set === 'undefined' ? undefined : Set,\n\t'%SetIteratorPrototype%': typeof Set === 'undefined' || !hasSymbols ? undefined : getProto(new Set()[Symbol.iterator]()),\n\t'%SetPrototype%': typeof Set === 'undefined' ? undefined : Set.prototype,\n\t'%SharedArrayBuffer%': typeof SharedArrayBuffer === 'undefined' ? undefined : SharedArrayBuffer,\n\t'%SharedArrayBufferPrototype%': typeof SharedArrayBuffer === 'undefined' ? undefined : SharedArrayBuffer.prototype,\n\t'%String%': String,\n\t'%StringIteratorPrototype%': hasSymbols ? getProto(''[Symbol.iterator]()) : undefined,\n\t'%StringPrototype%': String.prototype,\n\t'%Symbol%': hasSymbols ? Symbol : undefined,\n\t'%SymbolPrototype%': hasSymbols ? Symbol.prototype : undefined,\n\t'%SyntaxError%': SyntaxError,\n\t'%SyntaxErrorPrototype%': SyntaxError.prototype,\n\t'%ThrowTypeError%': ThrowTypeError,\n\t'%TypedArray%': TypedArray,\n\t'%TypedArrayPrototype%': TypedArray ? TypedArray.prototype : undefined,\n\t'%TypeError%': $TypeError,\n\t'%TypeErrorPrototype%': $TypeError.prototype,\n\t'%Uint8Array%': typeof Uint8Array === 'undefined' ? undefined : Uint8Array,\n\t'%Uint8ArrayPrototype%': typeof Uint8Array === 'undefined' ? undefined : Uint8Array.prototype,\n\t'%Uint8ClampedArray%': typeof Uint8ClampedArray === 'undefined' ? undefined : Uint8ClampedArray,\n\t'%Uint8ClampedArrayPrototype%': typeof Uint8ClampedArray === 'undefined' ? undefined : Uint8ClampedArray.prototype,\n\t'%Uint16Array%': typeof Uint16Array === 'undefined' ? undefined : Uint16Array,\n\t'%Uint16ArrayPrototype%': typeof Uint16Array === 'undefined' ? undefined : Uint16Array.prototype,\n\t'%Uint32Array%': typeof Uint32Array === 'undefined' ? undefined : Uint32Array,\n\t'%Uint32ArrayPrototype%': typeof Uint32Array === 'undefined' ? undefined : Uint32Array.prototype,\n\t'%URIError%': URIError,\n\t'%URIErrorPrototype%': URIError.prototype,\n\t'%WeakMap%': typeof WeakMap === 'undefined' ? undefined : WeakMap,\n\t'%WeakMapPrototype%': typeof WeakMap === 'undefined' ? undefined : WeakMap.prototype,\n\t'%WeakSet%': typeof WeakSet === 'undefined' ? undefined : WeakSet,\n\t'%WeakSetPrototype%': typeof WeakSet === 'undefined' ? undefined : WeakSet.prototype\n};\n\nvar bind = __webpack_require__(/*! function-bind */ \"./node_modules/function-bind/index.js\");\nvar $replace = bind.call(Function.call, String.prototype.replace);\n\n/* adapted from https://github.com/lodash/lodash/blob/4.17.15/dist/lodash.js#L6735-L6744 */\nvar rePropName = /[^%.[\\]]+|\\[(?:(-?\\d+(?:\\.\\d+)?)|([\"'])((?:(?!\\2)[^\\\\]|\\\\.)*?)\\2)\\]|(?=(?:\\.|\\[\\])(?:\\.|\\[\\]|%$))/g;\nvar reEscapeChar = /\\\\(\\\\)?/g; /** Used to match backslashes in property paths. */\nvar stringToPath = function stringToPath(string) {\n\tvar result = [];\n\t$replace(string, rePropName, function (match, number, quote, subString) {\n\t\tresult[result.length] = quote ? $replace(subString, reEscapeChar, '$1') : (number || match);\n\t});\n\treturn result;\n};\n/* end adaptation */\n\nvar getBaseIntrinsic = function getBaseIntrinsic(name, allowMissing) {\n\tif (!(name in INTRINSICS)) {\n\t\tthrow new SyntaxError('intrinsic ' + name + ' does not exist!');\n\t}\n\n\t// istanbul ignore if // hopefully this is impossible to test :-)\n\tif (typeof INTRINSICS[name] === 'undefined' && !allowMissing) {\n\t\tthrow new $TypeError('intrinsic ' + name + ' exists, but is not available. Please file an issue!');\n\t}\n\n\treturn INTRINSICS[name];\n};\n\nmodule.exports = function GetIntrinsic(name, allowMissing) {\n\tif (typeof name !== 'string' || name.length === 0) {\n\t\tthrow new TypeError('intrinsic name must be a non-empty string');\n\t}\n\tif (arguments.length > 1 && typeof allowMissing !== 'boolean') {\n\t\tthrow new TypeError('\"allowMissing\" argument must be a boolean');\n\t}\n\n\tvar parts = stringToPath(name);\n\n\tvar value = getBaseIntrinsic('%' + (parts.length > 0 ? parts[0] : '') + '%', allowMissing);\n\tfor (var i = 1; i < parts.length; i += 1) {\n\t\tif (value != null) {\n\t\t\tif ($gOPD && (i + 1) >= parts.length) {\n\t\t\t\tvar desc = $gOPD(value, parts[i]);\n\t\t\t\tif (!allowMissing && !(parts[i] in value)) {\n\t\t\t\t\tthrow new $TypeError('base intrinsic for ' + name + ' exists, but the property is not available.');\n\t\t\t\t}\n\t\t\t\tvalue = desc ? (desc.get || desc.value) : value[parts[i]];\n\t\t\t} else {\n\t\t\t\tvalue = value[parts[i]];\n\t\t\t}\n\t\t}\n\t}\n\treturn value;\n};\n\n\n//# sourceURL=webpack:///./node_modules/es-abstract/GetIntrinsic.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/es-abstract/helpers/callBind.js":
|
|
/*!******************************************************!*\
|
|
!*** ./node_modules/es-abstract/helpers/callBind.js ***!
|
|
\******************************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\nvar bind = __webpack_require__(/*! function-bind */ \"./node_modules/function-bind/index.js\");\n\nvar GetIntrinsic = __webpack_require__(/*! ../GetIntrinsic */ \"./node_modules/es-abstract/GetIntrinsic.js\");\n\nvar $apply = GetIntrinsic('%Function.prototype.apply%');\nvar $call = GetIntrinsic('%Function.prototype.call%');\nvar $reflectApply = GetIntrinsic('%Reflect.apply%', true) || bind.call($call, $apply);\n\nmodule.exports = function callBind() {\n\treturn $reflectApply(bind, $call, arguments);\n};\n\nmodule.exports.apply = function applyBind() {\n\treturn $reflectApply(bind, $apply, arguments);\n};\n\n\n//# sourceURL=webpack:///./node_modules/es-abstract/helpers/callBind.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/es-abstract/helpers/callBound.js":
|
|
/*!*******************************************************!*\
|
|
!*** ./node_modules/es-abstract/helpers/callBound.js ***!
|
|
\*******************************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\nvar GetIntrinsic = __webpack_require__(/*! ../GetIntrinsic */ \"./node_modules/es-abstract/GetIntrinsic.js\");\n\nvar callBind = __webpack_require__(/*! ./callBind */ \"./node_modules/es-abstract/helpers/callBind.js\");\n\nvar $indexOf = callBind(GetIntrinsic('String.prototype.indexOf'));\n\nmodule.exports = function callBoundIntrinsic(name, allowMissing) {\n\tvar intrinsic = GetIntrinsic(name, !!allowMissing);\n\tif (typeof intrinsic === 'function' && $indexOf(name, '.prototype.')) {\n\t\treturn callBind(intrinsic);\n\t}\n\treturn intrinsic;\n};\n\n\n//# sourceURL=webpack:///./node_modules/es-abstract/helpers/callBound.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/es-abstract/helpers/getOwnPropertyDescriptor.js":
|
|
/*!**********************************************************************!*\
|
|
!*** ./node_modules/es-abstract/helpers/getOwnPropertyDescriptor.js ***!
|
|
\**********************************************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\nvar GetIntrinsic = __webpack_require__(/*! ../GetIntrinsic */ \"./node_modules/es-abstract/GetIntrinsic.js\");\n\nvar $gOPD = GetIntrinsic('%Object.getOwnPropertyDescriptor%');\nif ($gOPD) {\n\ttry {\n\t\t$gOPD([], 'length');\n\t} catch (e) {\n\t\t// IE 8 has a broken gOPD\n\t\t$gOPD = null;\n\t}\n}\n\nmodule.exports = $gOPD;\n\n\n//# sourceURL=webpack:///./node_modules/es-abstract/helpers/getOwnPropertyDescriptor.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/es-get-iterator/index.js":
|
|
/*!***********************************************!*\
|
|
!*** ./node_modules/es-get-iterator/index.js ***!
|
|
\***********************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("/* WEBPACK VAR INJECTION */(function(process) {\n\n/* eslint global-require: 0 */\n// the code is structured this way so that bundlers can\n// alias out `has-symbols` to `() => true` or `() => false` if your target\n// environments' Symbol capabilities are known, and then use\n// dead code elimination on the rest of this module.\n//\n// Similarly, `isarray` can be aliased to `Array.isArray` if\n// available in all target environments.\n\nvar isArguments = __webpack_require__(/*! is-arguments */ \"./node_modules/is-arguments/index.js\");\n\nif (__webpack_require__(/*! has-symbols */ \"./node_modules/has-symbols/index.js\")() || __webpack_require__(/*! has-symbols/shams */ \"./node_modules/has-symbols/shams.js\")()) {\n\tvar $iterator = Symbol.iterator;\n\t// Symbol is available natively or shammed\n\t// natively:\n\t// - Chrome >= 38\n\t// - Edge 12-14?, Edge >= 15 for sure\n\t// - FF >= 36\n\t// - Safari >= 9\n\t// - node >= 0.12\n\tmodule.exports = function getIterator(iterable) {\n\t\t// alternatively, `iterable[$iterator]?.()`\n\t\tif (iterable != null && typeof iterable[$iterator] !== 'undefined') {\n\t\t\treturn iterable[$iterator]();\n\t\t}\n\t\tif (isArguments(iterable)) {\n\t\t\t// arguments objects lack Symbol.iterator\n\t\t\t// - node 0.12\n\t\t\treturn Array.prototype[$iterator].call(iterable);\n\t\t}\n\t};\n} else {\n\t// Symbol is not available, native or shammed\n\tvar isArray = __webpack_require__(/*! isarray */ \"./node_modules/es-get-iterator/node_modules/isarray/index.js\");\n\tvar isString = __webpack_require__(/*! is-string */ \"./node_modules/is-string/index.js\");\n\tvar GetIntrinsic = __webpack_require__(/*! es-abstract/GetIntrinsic */ \"./node_modules/es-abstract/GetIntrinsic.js\");\n\tvar $Map = GetIntrinsic('%Map%', true);\n\tvar $Set = GetIntrinsic('%Set%', true);\n\tvar callBound = __webpack_require__(/*! es-abstract/helpers/callBound */ \"./node_modules/es-abstract/helpers/callBound.js\");\n\tvar $arrayPush = callBound('Array.prototype.push');\n\tvar $charCodeAt = callBound('String.prototype.charCodeAt');\n\tvar $stringSlice = callBound('String.prototype.slice');\n\n\tvar advanceStringIndex = function advanceStringIndex(S, index) {\n\t\tvar length = S.length;\n\t\tif ((index + 1) >= length) {\n\t\t\treturn index + 1;\n\t\t}\n\n\t\tvar first = $charCodeAt(S, index);\n\t\tif (first < 0xD800 || first > 0xDBFF) {\n\t\t\treturn index + 1;\n\t\t}\n\n\t\tvar second = $charCodeAt(S, index + 1);\n\t\tif (second < 0xDC00 || second > 0xDFFF) {\n\t\t\treturn index + 1;\n\t\t}\n\n\t\treturn index + 2;\n\t};\n\n\tvar getArrayIterator = function getArrayIterator(arraylike) {\n\t\tvar i = 0;\n\t\treturn {\n\t\t\tnext: function next() {\n\t\t\t\tvar done = i >= arraylike.length;\n\t\t\t\tvar value;\n\t\t\t\tif (!done) {\n\t\t\t\t\tvalue = arraylike[i];\n\t\t\t\t\ti += 1;\n\t\t\t\t}\n\t\t\t\treturn {\n\t\t\t\t\tdone: done,\n\t\t\t\t\tvalue: value\n\t\t\t\t};\n\t\t\t}\n\t\t};\n\t};\n\n\tvar getNonCollectionIterator = function getNonCollectionIterator(iterable) {\n\t\tif (isArray(iterable) || isArguments(iterable)) {\n\t\t\treturn getArrayIterator(iterable);\n\t\t}\n\t\tif (isString(iterable)) {\n\t\t\tvar i = 0;\n\t\t\treturn {\n\t\t\t\tnext: function next() {\n\t\t\t\t\tvar nextIndex = advanceStringIndex(iterable, i);\n\t\t\t\t\tvar value = $stringSlice(iterable, i, nextIndex);\n\t\t\t\t\ti = nextIndex;\n\t\t\t\t\treturn {\n\t\t\t\t\t\tdone: nextIndex > iterable.length,\n\t\t\t\t\t\tvalue: value\n\t\t\t\t\t};\n\t\t\t\t}\n\t\t\t};\n\t\t}\n\t};\n\n\tif (!$Map && !$Set) {\n\t\t// the only language iterables are Array, String, arguments\n\t\t// - Safari <= 6.0\n\t\t// - Chrome < 38\n\t\t// - node < 0.12\n\t\t// - FF < 13\n\t\t// - IE < 11\n\t\t// - Edge < 11\n\n\t\tmodule.exports = getNonCollectionIterator;\n\t} else {\n\t\t// either Map or Set are available, but Symbol is not\n\t\t// - es6-shim on an ES5 browser\n\t\t// - Safari 6.2 (maybe 6.1?)\n\t\t// - FF v[13, 36)\n\t\t// - IE 11\n\t\t// - Edge 11\n\t\t// - Safari v[6, 9)\n\n\t\tvar isMap = __webpack_require__(/*! is-map */ \"./node_modules/is-map/index.js\");\n\t\tvar isSet = __webpack_require__(/*! is-set */ \"./node_modules/is-set/index.js\");\n\n\t\t// Firefox >= 27, IE 11, Safari 6.2 - 9, Edge 11, es6-shim in older envs, all have forEach\n\t\tvar $mapForEach = callBound('Map.prototype.forEach', true);\n\t\tvar $setForEach = callBound('Set.prototype.forEach', true);\n\t\tif (typeof process === 'undefined' || !process.versions || !process.versions.node) { // \"if is not node\"\n\n\t\t\t// Firefox 17 - 26 has `.iterator()`, whose iterator `.next()` either\n\t\t\t// returns a value, or throws a StopIteration object. These browsers\n\t\t\t// do not have any other mechanism for iteration.\n\t\t\tvar $mapIterator = callBound('Map.prototype.iterator', true);\n\t\t\tvar $setIterator = callBound('Set.prototype.iterator', true);\n\t\t\tvar getStopIterationIterator = function (iterator) {\n\t\t\t\tvar done = false;\n\t\t\t\treturn {\n\t\t\t\t\tnext: function next() {\n\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\treturn {\n\t\t\t\t\t\t\t\tdone: done,\n\t\t\t\t\t\t\t\tvalue: done ? undefined : iterator.next()\n\t\t\t\t\t\t\t};\n\t\t\t\t\t\t} catch (e) {\n\t\t\t\t\t\t\tdone = true;\n\t\t\t\t\t\t\treturn {\n\t\t\t\t\t\t\t\tdone: true,\n\t\t\t\t\t\t\t\tvalue: undefined\n\t\t\t\t\t\t\t};\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t};\n\t\t\t};\n\t\t}\n\t\t// Firefox 27-35, and some older es6-shim versions, use a string \"@@iterator\" property\n\t\t// this returns a proper iterator object, so we should use it instead of forEach.\n\t\t// newer es6-shim versions use a string \"_es6-shim iterator_\" property.\n\t\tvar $mapAtAtIterator = callBound('Map.prototype.@@iterator', true) || callBound('Map.prototype._es6-shim iterator_', true);\n\t\tvar $setAtAtIterator = callBound('Set.prototype.@@iterator', true) || callBound('Set.prototype._es6-shim iterator_', true);\n\n\t\tvar getCollectionIterator = function getCollectionIterator(iterable) {\n\t\t\tif (isMap(iterable)) {\n\t\t\t\tif ($mapIterator) {\n\t\t\t\t\treturn getStopIterationIterator($mapIterator(iterable));\n\t\t\t\t}\n\t\t\t\tif ($mapAtAtIterator) {\n\t\t\t\t\treturn $mapAtAtIterator(iterable);\n\t\t\t\t}\n\t\t\t\tif ($mapForEach) {\n\t\t\t\t\tvar entries = [];\n\t\t\t\t\t$mapForEach(iterable, function (v, k) {\n\t\t\t\t\t\t$arrayPush(entries, [k, v]);\n\t\t\t\t\t});\n\t\t\t\t\treturn getArrayIterator(entries);\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (isSet(iterable)) {\n\t\t\t\tif ($setIterator) {\n\t\t\t\t\treturn getStopIterationIterator($setIterator(iterable));\n\t\t\t\t}\n\t\t\t\tif ($setAtAtIterator) {\n\t\t\t\t\treturn $setAtAtIterator(iterable);\n\t\t\t\t}\n\t\t\t\tif ($setForEach) {\n\t\t\t\t\tvar values = [];\n\t\t\t\t\t$setForEach(iterable, function (v) {\n\t\t\t\t\t\t$arrayPush(values, v);\n\t\t\t\t\t});\n\t\t\t\t\treturn getArrayIterator(values);\n\t\t\t\t}\n\t\t\t}\n\t\t};\n\n\t\tmodule.exports = function getIterator(iterable) {\n\t\t\treturn getCollectionIterator(iterable) || getNonCollectionIterator(iterable);\n\t\t};\n\t}\n}\n\n/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./../process/browser.js */ \"./node_modules/process/browser.js\")))\n\n//# sourceURL=webpack:///./node_modules/es-get-iterator/index.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/es-get-iterator/node_modules/isarray/index.js":
|
|
/*!********************************************************************!*\
|
|
!*** ./node_modules/es-get-iterator/node_modules/isarray/index.js ***!
|
|
\********************************************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports) {
|
|
|
|
eval("var toString = {}.toString;\n\nmodule.exports = Array.isArray || function (arr) {\n return toString.call(arr) == '[object Array]';\n};\n\n\n//# sourceURL=webpack:///./node_modules/es-get-iterator/node_modules/isarray/index.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/foreach/index.js":
|
|
/*!***************************************!*\
|
|
!*** ./node_modules/foreach/index.js ***!
|
|
\***************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports) {
|
|
|
|
eval("\nvar hasOwn = Object.prototype.hasOwnProperty;\nvar toString = Object.prototype.toString;\n\nmodule.exports = function forEach (obj, fn, ctx) {\n if (toString.call(fn) !== '[object Function]') {\n throw new TypeError('iterator must be a function');\n }\n var l = obj.length;\n if (l === +l) {\n for (var i = 0; i < l; i++) {\n fn.call(ctx, obj[i], i, obj);\n }\n } else {\n for (var k in obj) {\n if (hasOwn.call(obj, k)) {\n fn.call(ctx, obj[k], k, obj);\n }\n }\n }\n};\n\n\n\n//# sourceURL=webpack:///./node_modules/foreach/index.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/function-bind/implementation.js":
|
|
/*!******************************************************!*\
|
|
!*** ./node_modules/function-bind/implementation.js ***!
|
|
\******************************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\n/* eslint no-invalid-this: 1 */\n\nvar ERROR_MESSAGE = 'Function.prototype.bind called on incompatible ';\nvar slice = Array.prototype.slice;\nvar toStr = Object.prototype.toString;\nvar funcType = '[object Function]';\n\nmodule.exports = function bind(that) {\n var target = this;\n if (typeof target !== 'function' || toStr.call(target) !== funcType) {\n throw new TypeError(ERROR_MESSAGE + target);\n }\n var args = slice.call(arguments, 1);\n\n var bound;\n var binder = function () {\n if (this instanceof bound) {\n var result = target.apply(\n this,\n args.concat(slice.call(arguments))\n );\n if (Object(result) === result) {\n return result;\n }\n return this;\n } else {\n return target.apply(\n that,\n args.concat(slice.call(arguments))\n );\n }\n };\n\n var boundLength = Math.max(0, target.length - args.length);\n var boundArgs = [];\n for (var i = 0; i < boundLength; i++) {\n boundArgs.push('$' + i);\n }\n\n bound = Function('binder', 'return function (' + boundArgs.join(',') + '){ return binder.apply(this,arguments); }')(binder);\n\n if (target.prototype) {\n var Empty = function Empty() {};\n Empty.prototype = target.prototype;\n bound.prototype = new Empty();\n Empty.prototype = null;\n }\n\n return bound;\n};\n\n\n//# sourceURL=webpack:///./node_modules/function-bind/implementation.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/function-bind/index.js":
|
|
/*!*********************************************!*\
|
|
!*** ./node_modules/function-bind/index.js ***!
|
|
\*********************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\nvar implementation = __webpack_require__(/*! ./implementation */ \"./node_modules/function-bind/implementation.js\");\n\nmodule.exports = Function.prototype.bind || implementation;\n\n\n//# sourceURL=webpack:///./node_modules/function-bind/index.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/has-symbols/index.js":
|
|
/*!*******************************************!*\
|
|
!*** ./node_modules/has-symbols/index.js ***!
|
|
\*******************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("/* WEBPACK VAR INJECTION */(function(global) {\n\nvar origSymbol = global.Symbol;\nvar hasSymbolSham = __webpack_require__(/*! ./shams */ \"./node_modules/has-symbols/shams.js\");\n\nmodule.exports = function hasNativeSymbols() {\n\tif (typeof origSymbol !== 'function') { return false; }\n\tif (typeof Symbol !== 'function') { return false; }\n\tif (typeof origSymbol('foo') !== 'symbol') { return false; }\n\tif (typeof Symbol('bar') !== 'symbol') { return false; }\n\n\treturn hasSymbolSham();\n};\n\n/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./../webpack/buildin/global.js */ \"./node_modules/webpack/buildin/global.js\")))\n\n//# sourceURL=webpack:///./node_modules/has-symbols/index.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/has-symbols/shams.js":
|
|
/*!*******************************************!*\
|
|
!*** ./node_modules/has-symbols/shams.js ***!
|
|
\*******************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\n/* eslint complexity: [2, 18], max-statements: [2, 33] */\nmodule.exports = function hasSymbols() {\n\tif (typeof Symbol !== 'function' || typeof Object.getOwnPropertySymbols !== 'function') { return false; }\n\tif (typeof Symbol.iterator === 'symbol') { return true; }\n\n\tvar obj = {};\n\tvar sym = Symbol('test');\n\tvar symObj = Object(sym);\n\tif (typeof sym === 'string') { return false; }\n\n\tif (Object.prototype.toString.call(sym) !== '[object Symbol]') { return false; }\n\tif (Object.prototype.toString.call(symObj) !== '[object Symbol]') { return false; }\n\n\t// temp disabled per https://github.com/ljharb/object.assign/issues/17\n\t// if (sym instanceof Symbol) { return false; }\n\t// temp disabled per https://github.com/WebReflection/get-own-property-symbols/issues/4\n\t// if (!(symObj instanceof Symbol)) { return false; }\n\n\t// if (typeof Symbol.prototype.toString !== 'function') { return false; }\n\t// if (String(sym) !== Symbol.prototype.toString.call(sym)) { return false; }\n\n\tvar symVal = 42;\n\tobj[sym] = symVal;\n\tfor (sym in obj) { return false; } // eslint-disable-line no-restricted-syntax\n\tif (typeof Object.keys === 'function' && Object.keys(obj).length !== 0) { return false; }\n\n\tif (typeof Object.getOwnPropertyNames === 'function' && Object.getOwnPropertyNames(obj).length !== 0) { return false; }\n\n\tvar syms = Object.getOwnPropertySymbols(obj);\n\tif (syms.length !== 1 || syms[0] !== sym) { return false; }\n\n\tif (!Object.prototype.propertyIsEnumerable.call(obj, sym)) { return false; }\n\n\tif (typeof Object.getOwnPropertyDescriptor === 'function') {\n\t\tvar descriptor = Object.getOwnPropertyDescriptor(obj, sym);\n\t\tif (descriptor.value !== symVal || descriptor.enumerable !== true) { return false; }\n\t}\n\n\treturn true;\n};\n\n\n//# sourceURL=webpack:///./node_modules/has-symbols/shams.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/is-arguments/index.js":
|
|
/*!********************************************!*\
|
|
!*** ./node_modules/is-arguments/index.js ***!
|
|
\********************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\nvar hasToStringTag = typeof Symbol === 'function' && typeof Symbol.toStringTag === 'symbol';\nvar toStr = Object.prototype.toString;\n\nvar isStandardArguments = function isArguments(value) {\n\tif (hasToStringTag && value && typeof value === 'object' && Symbol.toStringTag in value) {\n\t\treturn false;\n\t}\n\treturn toStr.call(value) === '[object Arguments]';\n};\n\nvar isLegacyArguments = function isArguments(value) {\n\tif (isStandardArguments(value)) {\n\t\treturn true;\n\t}\n\treturn value !== null &&\n\t\ttypeof value === 'object' &&\n\t\ttypeof value.length === 'number' &&\n\t\tvalue.length >= 0 &&\n\t\ttoStr.call(value) !== '[object Array]' &&\n\t\ttoStr.call(value.callee) === '[object Function]';\n};\n\nvar supportsStandardArguments = (function () {\n\treturn isStandardArguments(arguments);\n}());\n\nisStandardArguments.isLegacyArguments = isLegacyArguments; // for tests\n\nmodule.exports = supportsStandardArguments ? isStandardArguments : isLegacyArguments;\n\n\n//# sourceURL=webpack:///./node_modules/is-arguments/index.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/is-arrayish/index.js":
|
|
/*!*******************************************!*\
|
|
!*** ./node_modules/is-arrayish/index.js ***!
|
|
\*******************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports) {
|
|
|
|
eval("module.exports = function isArrayish(obj) {\n\tif (!obj || typeof obj === 'string') {\n\t\treturn false;\n\t}\n\n\treturn obj instanceof Array || Array.isArray(obj) ||\n\t\t(obj.length >= 0 && (obj.splice instanceof Function ||\n\t\t\t(Object.getOwnPropertyDescriptor(obj, (obj.length - 1)) && obj.constructor.name !== 'String')));\n};\n\n\n//# sourceURL=webpack:///./node_modules/is-arrayish/index.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/is-bigint/index.js":
|
|
/*!*****************************************!*\
|
|
!*** ./node_modules/is-bigint/index.js ***!
|
|
\*****************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\nif (typeof BigInt === 'function') {\n\tvar bigIntValueOf = BigInt.prototype.valueOf;\n\tvar tryBigInt = function tryBigIntObject(value) {\n\t\ttry {\n\t\t\tbigIntValueOf.call(value);\n\t\t\treturn true;\n\t\t} catch (e) {\n\t\t}\n\t\treturn false;\n\t};\n\n\tmodule.exports = function isBigInt(value) {\n\t\tif (\n\t\t\tvalue === null\n\t\t\t|| typeof value === 'undefined'\n\t\t\t|| typeof value === 'boolean'\n\t\t\t|| typeof value === 'string'\n\t\t\t|| typeof value === 'number'\n\t\t\t|| typeof value === 'symbol'\n\t\t\t|| typeof value === 'function'\n\t\t) {\n\t\t\treturn false;\n\t\t}\n\t\tif (typeof value === 'bigint') { // eslint-disable-line valid-typeof\n\t\t\treturn true;\n\t\t}\n\n\t\treturn tryBigInt(value);\n\t};\n} else {\n\tmodule.exports = function isBigInt(value) {\n\t\treturn false && false;\n\t};\n}\n\n\n//# sourceURL=webpack:///./node_modules/is-bigint/index.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/is-boolean-object/index.js":
|
|
/*!*************************************************!*\
|
|
!*** ./node_modules/is-boolean-object/index.js ***!
|
|
\*************************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\nvar boolToStr = Boolean.prototype.toString;\n\nvar tryBooleanObject = function booleanBrandCheck(value) {\n\ttry {\n\t\tboolToStr.call(value);\n\t\treturn true;\n\t} catch (e) {\n\t\treturn false;\n\t}\n};\nvar toStr = Object.prototype.toString;\nvar boolClass = '[object Boolean]';\nvar hasToStringTag = typeof Symbol === 'function' && typeof Symbol.toStringTag === 'symbol';\n\nmodule.exports = function isBoolean(value) {\n\tif (typeof value === 'boolean') {\n\t\treturn true;\n\t}\n\tif (value === null || typeof value !== 'object') {\n\t\treturn false;\n\t}\n\treturn hasToStringTag && Symbol.toStringTag in value ? tryBooleanObject(value) : toStr.call(value) === boolClass;\n};\n\n\n//# sourceURL=webpack:///./node_modules/is-boolean-object/index.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/is-date-object/index.js":
|
|
/*!**********************************************!*\
|
|
!*** ./node_modules/is-date-object/index.js ***!
|
|
\**********************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\nvar getDay = Date.prototype.getDay;\nvar tryDateObject = function tryDateGetDayCall(value) {\n\ttry {\n\t\tgetDay.call(value);\n\t\treturn true;\n\t} catch (e) {\n\t\treturn false;\n\t}\n};\n\nvar toStr = Object.prototype.toString;\nvar dateClass = '[object Date]';\nvar hasToStringTag = typeof Symbol === 'function' && typeof Symbol.toStringTag === 'symbol';\n\nmodule.exports = function isDateObject(value) {\n\tif (typeof value !== 'object' || value === null) {\n\t\treturn false;\n\t}\n\treturn hasToStringTag ? tryDateObject(value) : toStr.call(value) === dateClass;\n};\n\n\n//# sourceURL=webpack:///./node_modules/is-date-object/index.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/is-map/index.js":
|
|
/*!**************************************!*\
|
|
!*** ./node_modules/is-map/index.js ***!
|
|
\**************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\nvar $Map = typeof Map === 'function' && Map.prototype ? Map : null;\nvar $Set = typeof Set === 'function' && Set.prototype ? Set : null;\n\nvar exported;\n\nif (!$Map) {\n\t// eslint-disable-next-line no-unused-vars\n\texported = function isMap(x) {\n\t\t// `Map` is not present in this environment.\n\t\treturn false;\n\t};\n}\n\nvar $mapHas = $Map ? Map.prototype.has : null;\nvar $setHas = $Set ? Set.prototype.has : null;\nif (!exported && !$mapHas) {\n\t// eslint-disable-next-line no-unused-vars\n\texported = function isMap(x) {\n\t\t// `Map` does not have a `has` method\n\t\treturn false;\n\t};\n}\n\nmodule.exports = exported || function isMap(x) {\n\tif (!x || typeof x !== 'object') {\n\t\treturn false;\n\t}\n\ttry {\n\t\t$mapHas.call(x);\n\t\tif ($setHas) {\n\t\t\ttry {\n\t\t\t\t$setHas.call(x);\n\t\t\t} catch (e) {\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\t\treturn x instanceof $Map; // core-js workaround, pre-v2.5.0\n\t} catch (e) {}\n\treturn false;\n};\n\n\n//# sourceURL=webpack:///./node_modules/is-map/index.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/is-number-object/index.js":
|
|
/*!************************************************!*\
|
|
!*** ./node_modules/is-number-object/index.js ***!
|
|
\************************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\nvar numToStr = Number.prototype.toString;\nvar tryNumberObject = function tryNumberObject(value) {\n\ttry {\n\t\tnumToStr.call(value);\n\t\treturn true;\n\t} catch (e) {\n\t\treturn false;\n\t}\n};\nvar toStr = Object.prototype.toString;\nvar numClass = '[object Number]';\nvar hasToStringTag = typeof Symbol === 'function' && typeof Symbol.toStringTag === 'symbol';\n\nmodule.exports = function isNumberObject(value) {\n\tif (typeof value === 'number') {\n\t\treturn true;\n\t}\n\tif (typeof value !== 'object') {\n\t\treturn false;\n\t}\n\treturn hasToStringTag ? tryNumberObject(value) : toStr.call(value) === numClass;\n};\n\n\n//# sourceURL=webpack:///./node_modules/is-number-object/index.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/is-regex/index.js":
|
|
/*!****************************************!*\
|
|
!*** ./node_modules/is-regex/index.js ***!
|
|
\****************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\nvar hasSymbols = __webpack_require__(/*! has-symbols */ \"./node_modules/has-symbols/index.js\")();\nvar hasToStringTag = hasSymbols && typeof Symbol.toStringTag === 'symbol';\nvar regexExec;\nvar isRegexMarker;\nvar badStringifier;\n\nif (hasToStringTag) {\n\tregexExec = Function.call.bind(RegExp.prototype.exec);\n\tisRegexMarker = {};\n\n\tvar throwRegexMarker = function () {\n\t\tthrow isRegexMarker;\n\t};\n\tbadStringifier = {\n\t\ttoString: throwRegexMarker,\n\t\tvalueOf: throwRegexMarker\n\t};\n\n\tif (typeof Symbol.toPrimitive === 'symbol') {\n\t\tbadStringifier[Symbol.toPrimitive] = throwRegexMarker;\n\t}\n}\n\nvar toStr = Object.prototype.toString;\nvar regexClass = '[object RegExp]';\n\nmodule.exports = hasToStringTag\n\t// eslint-disable-next-line consistent-return\n\t? function isRegex(value) {\n\t\tif (!value || typeof value !== 'object') {\n\t\t\treturn false;\n\t\t}\n\n\t\ttry {\n\t\t\tregexExec(value, badStringifier);\n\t\t} catch (e) {\n\t\t\treturn e === isRegexMarker;\n\t\t}\n\t}\n\t: function isRegex(value) {\n\t\t// In older browsers, typeof regex incorrectly returns 'function'\n\t\tif (!value || (typeof value !== 'object' && typeof value !== 'function')) {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn toStr.call(value) === regexClass;\n\t};\n\n\n//# sourceURL=webpack:///./node_modules/is-regex/index.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/is-set/index.js":
|
|
/*!**************************************!*\
|
|
!*** ./node_modules/is-set/index.js ***!
|
|
\**************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\nvar $Map = typeof Map === 'function' && Map.prototype ? Map : null;\nvar $Set = typeof Set === 'function' && Set.prototype ? Set : null;\n\nvar exported;\n\nif (!$Set) {\n\t// eslint-disable-next-line no-unused-vars\n\texported = function isSet(x) {\n\t\t// `Set` is not present in this environment.\n\t\treturn false;\n\t};\n}\n\nvar $mapHas = $Map ? Map.prototype.has : null;\nvar $setHas = $Set ? Set.prototype.has : null;\nif (!exported && !$setHas) {\n\t// eslint-disable-next-line no-unused-vars\n\texported = function isSet(x) {\n\t\t// `Set` does not have a `has` method\n\t\treturn false;\n\t};\n}\n\nmodule.exports = exported || function isSet(x) {\n\tif (!x || typeof x !== 'object') {\n\t\treturn false;\n\t}\n\ttry {\n\t\t$setHas.call(x);\n\t\tif ($mapHas) {\n\t\t\ttry {\n\t\t\t\t$mapHas.call(x);\n\t\t\t} catch (e) {\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\t\treturn x instanceof $Set; // core-js workaround, pre-v2.5.0\n\t} catch (e) {}\n\treturn false;\n};\n\n\n//# sourceURL=webpack:///./node_modules/is-set/index.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/is-string/index.js":
|
|
/*!*****************************************!*\
|
|
!*** ./node_modules/is-string/index.js ***!
|
|
\*****************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\nvar strValue = String.prototype.valueOf;\nvar tryStringObject = function tryStringObject(value) {\n\ttry {\n\t\tstrValue.call(value);\n\t\treturn true;\n\t} catch (e) {\n\t\treturn false;\n\t}\n};\nvar toStr = Object.prototype.toString;\nvar strClass = '[object String]';\nvar hasToStringTag = typeof Symbol === 'function' && typeof Symbol.toStringTag === 'symbol';\n\nmodule.exports = function isString(value) {\n\tif (typeof value === 'string') {\n\t\treturn true;\n\t}\n\tif (typeof value !== 'object') {\n\t\treturn false;\n\t}\n\treturn hasToStringTag ? tryStringObject(value) : toStr.call(value) === strClass;\n};\n\n\n//# sourceURL=webpack:///./node_modules/is-string/index.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/is-symbol/index.js":
|
|
/*!*****************************************!*\
|
|
!*** ./node_modules/is-symbol/index.js ***!
|
|
\*****************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\nvar toStr = Object.prototype.toString;\nvar hasSymbols = __webpack_require__(/*! has-symbols */ \"./node_modules/has-symbols/index.js\")();\n\nif (hasSymbols) {\n\tvar symToStr = Symbol.prototype.toString;\n\tvar symStringRegex = /^Symbol\\(.*\\)$/;\n\tvar isSymbolObject = function isRealSymbolObject(value) {\n\t\tif (typeof value.valueOf() !== 'symbol') {\n\t\t\treturn false;\n\t\t}\n\t\treturn symStringRegex.test(symToStr.call(value));\n\t};\n\n\tmodule.exports = function isSymbol(value) {\n\t\tif (typeof value === 'symbol') {\n\t\t\treturn true;\n\t\t}\n\t\tif (toStr.call(value) !== '[object Symbol]') {\n\t\t\treturn false;\n\t\t}\n\t\ttry {\n\t\t\treturn isSymbolObject(value);\n\t\t} catch (e) {\n\t\t\treturn false;\n\t\t}\n\t};\n} else {\n\n\tmodule.exports = function isSymbol(value) {\n\t\t// this environment does not support Symbols.\n\t\treturn false && false;\n\t};\n}\n\n\n//# sourceURL=webpack:///./node_modules/is-symbol/index.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/is-typed-array/index.js":
|
|
/*!**********************************************!*\
|
|
!*** ./node_modules/is-typed-array/index.js ***!
|
|
\**********************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("/* WEBPACK VAR INJECTION */(function(global) {\n\nvar forEach = __webpack_require__(/*! foreach */ \"./node_modules/foreach/index.js\");\nvar availableTypedArrays = __webpack_require__(/*! available-typed-arrays */ \"./node_modules/available-typed-arrays/index.js\");\nvar callBound = __webpack_require__(/*! es-abstract/helpers/callBound */ \"./node_modules/es-abstract/helpers/callBound.js\");\n\nvar $toString = callBound('Object.prototype.toString');\nvar hasSymbols = __webpack_require__(/*! has-symbols */ \"./node_modules/has-symbols/index.js\")();\nvar hasToStringTag = hasSymbols && typeof Symbol.toStringTag === 'symbol';\n\nvar typedArrays = availableTypedArrays();\n\nvar $indexOf = callBound('Array.prototype.indexOf', true) || function indexOf(array, value) {\n\tfor (var i = 0; i < array.length; i += 1) {\n\t\tif (array[i] === value) {\n\t\t\treturn i;\n\t\t}\n\t}\n\treturn -1;\n};\nvar $slice = callBound('String.prototype.slice');\nvar toStrTags = {};\nvar gOPD = __webpack_require__(/*! es-abstract/helpers/getOwnPropertyDescriptor */ \"./node_modules/es-abstract/helpers/getOwnPropertyDescriptor.js\");\nvar getPrototypeOf = Object.getPrototypeOf; // require('getprototypeof');\nif (hasToStringTag && gOPD && getPrototypeOf) {\n\tforEach(typedArrays, function (typedArray) {\n\t\tvar arr = new global[typedArray]();\n\t\tif (!(Symbol.toStringTag in arr)) {\n\t\t\tthrow new EvalError('this engine has support for Symbol.toStringTag, but ' + typedArray + ' does not have the property! Please report this.');\n\t\t}\n\t\tvar proto = getPrototypeOf(arr);\n\t\tvar descriptor = gOPD(proto, Symbol.toStringTag);\n\t\tif (!descriptor) {\n\t\t\tvar superProto = getPrototypeOf(proto);\n\t\t\tdescriptor = gOPD(superProto, Symbol.toStringTag);\n\t\t}\n\t\ttoStrTags[typedArray] = descriptor.get;\n\t});\n}\n\nvar tryTypedArrays = function tryAllTypedArrays(value) {\n\tvar anyTrue = false;\n\tforEach(toStrTags, function (getter, typedArray) {\n\t\tif (!anyTrue) {\n\t\t\ttry {\n\t\t\t\tanyTrue = getter.call(value) === typedArray;\n\t\t\t} catch (e) { /**/ }\n\t\t}\n\t});\n\treturn anyTrue;\n};\n\nmodule.exports = function isTypedArray(value) {\n\tif (!value || typeof value !== 'object') { return false; }\n\tif (!hasToStringTag) {\n\t\tvar tag = $slice($toString(value), 8, -1);\n\t\treturn $indexOf(typedArrays, tag) > -1;\n\t}\n\tif (!gOPD) { return false; }\n\treturn tryTypedArrays(value);\n};\n\n/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./../webpack/buildin/global.js */ \"./node_modules/webpack/buildin/global.js\")))\n\n//# sourceURL=webpack:///./node_modules/is-typed-array/index.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/is-weakmap/index.js":
|
|
/*!******************************************!*\
|
|
!*** ./node_modules/is-weakmap/index.js ***!
|
|
\******************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\nvar $WeakMap = typeof WeakMap === 'function' && WeakMap.prototype ? WeakMap : null;\nvar $WeakSet = typeof WeakSet === 'function' && WeakSet.prototype ? WeakSet : null;\n\nvar exported;\n\nif (!$WeakMap) {\n\t// eslint-disable-next-line no-unused-vars\n\texported = function isWeakMap(x) {\n\t\t// `WeakMap` is not present in this environment.\n\t\treturn false;\n\t};\n}\n\nvar $mapHas = $WeakMap ? $WeakMap.prototype.has : null;\nvar $setHas = $WeakSet ? $WeakSet.prototype.has : null;\nif (!exported && !$mapHas) {\n\t// eslint-disable-next-line no-unused-vars\n\texported = function isWeakMap(x) {\n\t\t// `WeakMap` does not have a `has` method\n\t\treturn false;\n\t};\n}\n\nmodule.exports = exported || function isWeakMap(x) {\n\tif (!x || typeof x !== 'object') {\n\t\treturn false;\n\t}\n\ttry {\n\t\t$mapHas.call(x, $mapHas);\n\t\tif ($setHas) {\n\t\t\ttry {\n\t\t\t\t$setHas.call(x, $setHas);\n\t\t\t} catch (e) {\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\t\treturn x instanceof $WeakMap; // core-js workaround, pre-v3\n\t} catch (e) {}\n\treturn false;\n};\n\n\n//# sourceURL=webpack:///./node_modules/is-weakmap/index.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/is-weakset/index.js":
|
|
/*!******************************************!*\
|
|
!*** ./node_modules/is-weakset/index.js ***!
|
|
\******************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\nvar $WeakMap = typeof WeakMap === 'function' && WeakMap.prototype ? WeakMap : null;\nvar $WeakSet = typeof WeakSet === 'function' && WeakSet.prototype ? WeakSet : null;\n\nvar exported;\n\nif (!$WeakMap) {\n\t// eslint-disable-next-line no-unused-vars\n\texported = function isWeakSet(x) {\n\t\t// `WeakSet` is not present in this environment.\n\t\treturn false;\n\t};\n}\n\nvar $mapHas = $WeakMap ? $WeakMap.prototype.has : null;\nvar $setHas = $WeakSet ? $WeakSet.prototype.has : null;\nif (!exported && !$setHas) {\n\t// eslint-disable-next-line no-unused-vars\n\tmodule.exports = function isWeakSet(x) {\n\t\t// `WeakSet` does not have a `has` method\n\t\treturn false;\n\t};\n}\n\nmodule.exports = exported || function isWeakSet(x) {\n\tif (!x || typeof x !== 'object') {\n\t\treturn false;\n\t}\n\ttry {\n\t\t$setHas.call(x, $setHas);\n\t\tif ($mapHas) {\n\t\t\ttry {\n\t\t\t\t$mapHas.call(x, $mapHas);\n\t\t\t} catch (e) {\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\t\treturn x instanceof $WeakSet; // core-js workaround, pre-v3\n\t} catch (e) {}\n\treturn false;\n};\n\n\n//# sourceURL=webpack:///./node_modules/is-weakset/index.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/lit-element/lib/css-tag.js":
|
|
/*!*************************************************!*\
|
|
!*** ./node_modules/lit-element/lib/css-tag.js ***!
|
|
\*************************************************/
|
|
/*! exports provided: supportsAdoptingStyleSheets, CSSResult, unsafeCSS, css */
|
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"supportsAdoptingStyleSheets\", function() { return supportsAdoptingStyleSheets; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"CSSResult\", function() { return CSSResult; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"unsafeCSS\", function() { return unsafeCSS; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"css\", function() { return css; });\n/**\n@license\nCopyright (c) 2019 The Polymer Project Authors. All rights reserved.\nThis code may only be used under the BSD style license found at\nhttp://polymer.github.io/LICENSE.txt The complete set of authors may be found at\nhttp://polymer.github.io/AUTHORS.txt The complete set of contributors may be\nfound at http://polymer.github.io/CONTRIBUTORS.txt Code distributed by Google as\npart of the polymer project is also subject to an additional IP rights grant\nfound at http://polymer.github.io/PATENTS.txt\n*/\nconst supportsAdoptingStyleSheets = ('adoptedStyleSheets' in Document.prototype) &&\n ('replace' in CSSStyleSheet.prototype);\nconst constructionToken = Symbol();\nclass CSSResult {\n constructor(cssText, safeToken) {\n if (safeToken !== constructionToken) {\n throw new Error('CSSResult is not constructable. Use `unsafeCSS` or `css` instead.');\n }\n this.cssText = cssText;\n }\n // Note, this is a getter so that it's lazy. In practice, this means\n // stylesheets are not created until the first element instance is made.\n get styleSheet() {\n if (this._styleSheet === undefined) {\n // Note, if `adoptedStyleSheets` is supported then we assume CSSStyleSheet\n // is constructable.\n if (supportsAdoptingStyleSheets) {\n this._styleSheet = new CSSStyleSheet();\n this._styleSheet.replaceSync(this.cssText);\n }\n else {\n this._styleSheet = null;\n }\n }\n return this._styleSheet;\n }\n toString() {\n return this.cssText;\n }\n}\n/**\n * Wrap a value for interpolation in a css tagged template literal.\n *\n * This is unsafe because untrusted CSS text can be used to phone home\n * or exfiltrate data to an attacker controlled site. Take care to only use\n * this with trusted input.\n */\nconst unsafeCSS = (value) => {\n return new CSSResult(String(value), constructionToken);\n};\nconst textFromCSSResult = (value) => {\n if (value instanceof CSSResult) {\n return value.cssText;\n }\n else if (typeof value === 'number') {\n return value;\n }\n else {\n throw new Error(`Value passed to 'css' function must be a 'css' function result: ${value}. Use 'unsafeCSS' to pass non-literal values, but\n take care to ensure page security.`);\n }\n};\n/**\n * Template tag which which can be used with LitElement's `style` property to\n * set element styles. For security reasons, only literal string values may be\n * used. To incorporate non-literal values `unsafeCSS` may be used inside a\n * template string part.\n */\nconst css = (strings, ...values) => {\n const cssText = values.reduce((acc, v, idx) => acc + textFromCSSResult(v) + strings[idx + 1], strings[0]);\n return new CSSResult(cssText, constructionToken);\n};\n//# sourceMappingURL=css-tag.js.map\n\n//# sourceURL=webpack:///./node_modules/lit-element/lib/css-tag.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/lit-element/lib/decorators.js":
|
|
/*!****************************************************!*\
|
|
!*** ./node_modules/lit-element/lib/decorators.js ***!
|
|
\****************************************************/
|
|
/*! exports provided: customElement, property, internalProperty, query, queryAsync, queryAll, eventOptions, queryAssignedNodes */
|
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"customElement\", function() { return customElement; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"property\", function() { return property; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"internalProperty\", function() { return internalProperty; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"query\", function() { return query; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"queryAsync\", function() { return queryAsync; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"queryAll\", function() { return queryAll; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"eventOptions\", function() { return eventOptions; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"queryAssignedNodes\", function() { return queryAssignedNodes; });\n/**\n * @license\n * Copyright (c) 2017 The Polymer Project Authors. All rights reserved.\n * This code may only be used under the BSD style license found at\n * http://polymer.github.io/LICENSE.txt\n * The complete set of authors may be found at\n * http://polymer.github.io/AUTHORS.txt\n * The complete set of contributors may be found at\n * http://polymer.github.io/CONTRIBUTORS.txt\n * Code distributed by Google as part of the polymer project is also\n * subject to an additional IP rights grant found at\n * http://polymer.github.io/PATENTS.txt\n */\nconst legacyCustomElement = (tagName, clazz) => {\n window.customElements.define(tagName, clazz);\n // Cast as any because TS doesn't recognize the return type as being a\n // subtype of the decorated class when clazz is typed as\n // `Constructor<HTMLElement>` for some reason.\n // `Constructor<HTMLElement>` is helpful to make sure the decorator is\n // applied to elements however.\n // tslint:disable-next-line:no-any\n return clazz;\n};\nconst standardCustomElement = (tagName, descriptor) => {\n const { kind, elements } = descriptor;\n return {\n kind,\n elements,\n // This callback is called once the class is otherwise fully defined\n finisher(clazz) {\n window.customElements.define(tagName, clazz);\n }\n };\n};\n/**\n * Class decorator factory that defines the decorated class as a custom element.\n *\n * ```\n * @customElement('my-element')\n * class MyElement {\n * render() {\n * return html``;\n * }\n * }\n * ```\n *\n * @param tagName The name of the custom element to define.\n */\nconst customElement = (tagName) => (classOrDescriptor) => (typeof classOrDescriptor === 'function') ?\n legacyCustomElement(tagName, classOrDescriptor) :\n standardCustomElement(tagName, classOrDescriptor);\nconst standardProperty = (options, element) => {\n // When decorating an accessor, pass it through and add property metadata.\n // Note, the `hasOwnProperty` check in `createProperty` ensures we don't\n // stomp over the user's accessor.\n if (element.kind === 'method' && element.descriptor &&\n !('value' in element.descriptor)) {\n return Object.assign(Object.assign({}, element), { finisher(clazz) {\n clazz.createProperty(element.key, options);\n } });\n }\n else {\n // createProperty() takes care of defining the property, but we still\n // must return some kind of descriptor, so return a descriptor for an\n // unused prototype field. The finisher calls createProperty().\n return {\n kind: 'field',\n key: Symbol(),\n placement: 'own',\n descriptor: {},\n // When @babel/plugin-proposal-decorators implements initializers,\n // do this instead of the initializer below. See:\n // https://github.com/babel/babel/issues/9260 extras: [\n // {\n // kind: 'initializer',\n // placement: 'own',\n // initializer: descriptor.initializer,\n // }\n // ],\n initializer() {\n if (typeof element.initializer === 'function') {\n this[element.key] = element.initializer.call(this);\n }\n },\n finisher(clazz) {\n clazz.createProperty(element.key, options);\n }\n };\n }\n};\nconst legacyProperty = (options, proto, name) => {\n proto.constructor\n .createProperty(name, options);\n};\n/**\n * A property decorator which creates a LitElement property which reflects a\n * corresponding attribute value. A `PropertyDeclaration` may optionally be\n * supplied to configure property features.\n *\n * This decorator should only be used for public fields. Private or protected\n * fields should use the internalProperty decorator.\n *\n * @example\n *\n * class MyElement {\n * @property({ type: Boolean })\n * clicked = false;\n * }\n *\n * @ExportDecoratedItems\n */\nfunction property(options) {\n // tslint:disable-next-line:no-any decorator\n return (protoOrDescriptor, name) => (name !== undefined) ?\n legacyProperty(options, protoOrDescriptor, name) :\n standardProperty(options, protoOrDescriptor);\n}\n/**\n * Declares a private or protected property that still triggers updates to the\n * element when it changes.\n *\n * Properties declared this way must not be used from HTML or HTML templating\n * systems, they're solely for properties internal to the element. These\n * properties may be renamed by optimization tools like closure compiler.\n */\nfunction internalProperty(options) {\n return property({ attribute: false, hasChanged: options === null || options === void 0 ? void 0 : options.hasChanged });\n}\n/**\n * A property decorator that converts a class property into a getter that\n * executes a querySelector on the element's renderRoot.\n *\n * @param selector A DOMString containing one or more selectors to match.\n *\n * See: https://developer.mozilla.org/en-US/docs/Web/API/Document/querySelector\n *\n * @example\n *\n * class MyElement {\n * @query('#first')\n * first;\n *\n * render() {\n * return html`\n * <div id=\"first\"></div>\n * <div id=\"second\"></div>\n * `;\n * }\n * }\n *\n */\nfunction query(selector) {\n return (protoOrDescriptor, \n // tslint:disable-next-line:no-any decorator\n name) => {\n const descriptor = {\n get() {\n return this.renderRoot.querySelector(selector);\n },\n enumerable: true,\n configurable: true,\n };\n return (name !== undefined) ?\n legacyQuery(descriptor, protoOrDescriptor, name) :\n standardQuery(descriptor, protoOrDescriptor);\n };\n}\n// Note, in the future, we may extend this decorator to support the use case\n// where the queried element may need to do work to become ready to interact\n// with (e.g. load some implementation code). If so, we might elect to\n// add a second argument defining a function that can be run to make the\n// queried element loaded/updated/ready.\n/**\n * A property decorator that converts a class property into a getter that\n * returns a promise that resolves to the result of a querySelector on the\n * element's renderRoot done after the element's `updateComplete` promise\n * resolves. When the queried property may change with element state, this\n * decorator can be used instead of requiring users to await the\n * `updateComplete` before accessing the property.\n *\n * @param selector A DOMString containing one or more selectors to match.\n *\n * See: https://developer.mozilla.org/en-US/docs/Web/API/Document/querySelector\n *\n * @example\n *\n * class MyElement {\n * @queryAsync('#first')\n * first;\n *\n * render() {\n * return html`\n * <div id=\"first\"></div>\n * <div id=\"second\"></div>\n * `;\n * }\n * }\n *\n * // external usage\n * async doSomethingWithFirst() {\n * (await aMyElement.first).doSomething();\n * }\n */\nfunction queryAsync(selector) {\n return (protoOrDescriptor, \n // tslint:disable-next-line:no-any decorator\n name) => {\n const descriptor = {\n async get() {\n await this.updateComplete;\n return this.renderRoot.querySelector(selector);\n },\n enumerable: true,\n configurable: true,\n };\n return (name !== undefined) ?\n legacyQuery(descriptor, protoOrDescriptor, name) :\n standardQuery(descriptor, protoOrDescriptor);\n };\n}\n/**\n * A property decorator that converts a class property into a getter\n * that executes a querySelectorAll on the element's renderRoot.\n *\n * @param selector A DOMString containing one or more selectors to match.\n *\n * See:\n * https://developer.mozilla.org/en-US/docs/Web/API/Document/querySelectorAll\n *\n * @example\n *\n * class MyElement {\n * @queryAll('div')\n * divs;\n *\n * render() {\n * return html`\n * <div id=\"first\"></div>\n * <div id=\"second\"></div>\n * `;\n * }\n * }\n */\nfunction queryAll(selector) {\n return (protoOrDescriptor, \n // tslint:disable-next-line:no-any decorator\n name) => {\n const descriptor = {\n get() {\n return this.renderRoot.querySelectorAll(selector);\n },\n enumerable: true,\n configurable: true,\n };\n return (name !== undefined) ?\n legacyQuery(descriptor, protoOrDescriptor, name) :\n standardQuery(descriptor, protoOrDescriptor);\n };\n}\nconst legacyQuery = (descriptor, proto, name) => {\n Object.defineProperty(proto, name, descriptor);\n};\nconst standardQuery = (descriptor, element) => ({\n kind: 'method',\n placement: 'prototype',\n key: element.key,\n descriptor,\n});\nconst standardEventOptions = (options, element) => {\n return Object.assign(Object.assign({}, element), { finisher(clazz) {\n Object.assign(clazz.prototype[element.key], options);\n } });\n};\nconst legacyEventOptions = \n// tslint:disable-next-line:no-any legacy decorator\n(options, proto, name) => {\n Object.assign(proto[name], options);\n};\n/**\n * Adds event listener options to a method used as an event listener in a\n * lit-html template.\n *\n * @param options An object that specifies event listener options as accepted by\n * `EventTarget#addEventListener` and `EventTarget#removeEventListener`.\n *\n * Current browsers support the `capture`, `passive`, and `once` options. See:\n * https://developer.mozilla.org/en-US/docs/Web/API/EventTarget/addEventListener#Parameters\n *\n * @example\n *\n * class MyElement {\n * clicked = false;\n *\n * render() {\n * return html`\n * <div @click=${this._onClick}`>\n * <button></button>\n * </div>\n * `;\n * }\n *\n * @eventOptions({capture: true})\n * _onClick(e) {\n * this.clicked = true;\n * }\n * }\n */\nfunction eventOptions(options) {\n // Return value typed as any to prevent TypeScript from complaining that\n // standard decorator function signature does not match TypeScript decorator\n // signature\n // TODO(kschaaf): unclear why it was only failing on this decorator and not\n // the others\n return ((protoOrDescriptor, name) => (name !== undefined) ?\n legacyEventOptions(options, protoOrDescriptor, name) :\n standardEventOptions(options, protoOrDescriptor));\n}\n/**\n * A property decorator that converts a class property into a getter that\n * returns the `assignedNodes` of the given named `slot`. Note, the type of\n * this property should be annotated as `NodeListOf<HTMLElement>`.\n *\n */\nfunction queryAssignedNodes(slotName = '', flatten = false) {\n return (protoOrDescriptor, \n // tslint:disable-next-line:no-any decorator\n name) => {\n const descriptor = {\n get() {\n const selector = `slot${slotName ? `[name=${slotName}]` : ''}`;\n const slot = this.renderRoot.querySelector(selector);\n return slot && slot.assignedNodes({ flatten });\n },\n enumerable: true,\n configurable: true,\n };\n return (name !== undefined) ?\n legacyQuery(descriptor, protoOrDescriptor, name) :\n standardQuery(descriptor, protoOrDescriptor);\n };\n}\n//# sourceMappingURL=decorators.js.map\n\n//# sourceURL=webpack:///./node_modules/lit-element/lib/decorators.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/lit-element/lib/updating-element.js":
|
|
/*!**********************************************************!*\
|
|
!*** ./node_modules/lit-element/lib/updating-element.js ***!
|
|
\**********************************************************/
|
|
/*! exports provided: defaultConverter, notEqual, UpdatingElement */
|
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"defaultConverter\", function() { return defaultConverter; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"notEqual\", function() { return notEqual; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"UpdatingElement\", function() { return UpdatingElement; });\n/**\n * @license\n * Copyright (c) 2017 The Polymer Project Authors. All rights reserved.\n * This code may only be used under the BSD style license found at\n * http://polymer.github.io/LICENSE.txt\n * The complete set of authors may be found at\n * http://polymer.github.io/AUTHORS.txt\n * The complete set of contributors may be found at\n * http://polymer.github.io/CONTRIBUTORS.txt\n * Code distributed by Google as part of the polymer project is also\n * subject to an additional IP rights grant found at\n * http://polymer.github.io/PATENTS.txt\n */\nvar _a;\n/**\n * When using Closure Compiler, JSCompiler_renameProperty(property, object) is\n * replaced at compile time by the munged name for object[property]. We cannot\n * alias this function, so we have to use a small shim that has the same\n * behavior when not compiling.\n */\nwindow.JSCompiler_renameProperty =\n (prop, _obj) => prop;\nconst defaultConverter = {\n toAttribute(value, type) {\n switch (type) {\n case Boolean:\n return value ? '' : null;\n case Object:\n case Array:\n // if the value is `null` or `undefined` pass this through\n // to allow removing/no change behavior.\n return value == null ? value : JSON.stringify(value);\n }\n return value;\n },\n fromAttribute(value, type) {\n switch (type) {\n case Boolean:\n return value !== null;\n case Number:\n return value === null ? null : Number(value);\n case Object:\n case Array:\n return JSON.parse(value);\n }\n return value;\n }\n};\n/**\n * Change function that returns true if `value` is different from `oldValue`.\n * This method is used as the default for a property's `hasChanged` function.\n */\nconst notEqual = (value, old) => {\n // This ensures (old==NaN, value==NaN) always returns false\n return old !== value && (old === old || value === value);\n};\nconst defaultPropertyDeclaration = {\n attribute: true,\n type: String,\n converter: defaultConverter,\n reflect: false,\n hasChanged: notEqual\n};\nconst STATE_HAS_UPDATED = 1;\nconst STATE_UPDATE_REQUESTED = 1 << 2;\nconst STATE_IS_REFLECTING_TO_ATTRIBUTE = 1 << 3;\nconst STATE_IS_REFLECTING_TO_PROPERTY = 1 << 4;\n/**\n * The Closure JS Compiler doesn't currently have good support for static\n * property semantics where \"this\" is dynamic (e.g.\n * https://github.com/google/closure-compiler/issues/3177 and others) so we use\n * this hack to bypass any rewriting by the compiler.\n */\nconst finalized = 'finalized';\n/**\n * Base element class which manages element properties and attributes. When\n * properties change, the `update` method is asynchronously called. This method\n * should be supplied by subclassers to render updates as desired.\n */\nclass UpdatingElement extends HTMLElement {\n constructor() {\n super();\n this._updateState = 0;\n this._instanceProperties = undefined;\n // Initialize to an unresolved Promise so we can make sure the element has\n // connected before first update.\n this._updatePromise = new Promise((res) => this._enableUpdatingResolver = res);\n /**\n * Map with keys for any properties that have changed since the last\n * update cycle with previous values.\n */\n this._changedProperties = new Map();\n /**\n * Map with keys of properties that should be reflected when updated.\n */\n this._reflectingProperties = undefined;\n this.initialize();\n }\n /**\n * Returns a list of attributes corresponding to the registered properties.\n * @nocollapse\n */\n static get observedAttributes() {\n // note: piggy backing on this to ensure we're finalized.\n this.finalize();\n const attributes = [];\n // Use forEach so this works even if for/of loops are compiled to for loops\n // expecting arrays\n this._classProperties.forEach((v, p) => {\n const attr = this._attributeNameForProperty(p, v);\n if (attr !== undefined) {\n this._attributeToPropertyMap.set(attr, p);\n attributes.push(attr);\n }\n });\n return attributes;\n }\n /**\n * Ensures the private `_classProperties` property metadata is created.\n * In addition to `finalize` this is also called in `createProperty` to\n * ensure the `@property` decorator can add property metadata.\n */\n /** @nocollapse */\n static _ensureClassProperties() {\n // ensure private storage for property declarations.\n if (!this.hasOwnProperty(JSCompiler_renameProperty('_classProperties', this))) {\n this._classProperties = new Map();\n // NOTE: Workaround IE11 not supporting Map constructor argument.\n const superProperties = Object.getPrototypeOf(this)._classProperties;\n if (superProperties !== undefined) {\n superProperties.forEach((v, k) => this._classProperties.set(k, v));\n }\n }\n }\n /**\n * Creates a property accessor on the element prototype if one does not exist\n * and stores a PropertyDeclaration for the property with the given options.\n * The property setter calls the property's `hasChanged` property option\n * or uses a strict identity check to determine whether or not to request\n * an update.\n *\n * This method may be overridden to customize properties; however,\n * when doing so, it's important to call `super.createProperty` to ensure\n * the property is setup correctly. This method calls\n * `getPropertyDescriptor` internally to get a descriptor to install.\n * To customize what properties do when they are get or set, override\n * `getPropertyDescriptor`. To customize the options for a property,\n * implement `createProperty` like this:\n *\n * static createProperty(name, options) {\n * options = Object.assign(options, {myOption: true});\n * super.createProperty(name, options);\n * }\n *\n * @nocollapse\n */\n static createProperty(name, options = defaultPropertyDeclaration) {\n // Note, since this can be called by the `@property` decorator which\n // is called before `finalize`, we ensure storage exists for property\n // metadata.\n this._ensureClassProperties();\n this._classProperties.set(name, options);\n // Do not generate an accessor if the prototype already has one, since\n // it would be lost otherwise and that would never be the user's intention;\n // Instead, we expect users to call `requestUpdate` themselves from\n // user-defined accessors. Note that if the super has an accessor we will\n // still overwrite it\n if (options.noAccessor || this.prototype.hasOwnProperty(name)) {\n return;\n }\n const key = typeof name === 'symbol' ? Symbol() : `__${name}`;\n const descriptor = this.getPropertyDescriptor(name, key, options);\n if (descriptor !== undefined) {\n Object.defineProperty(this.prototype, name, descriptor);\n }\n }\n /**\n * Returns a property descriptor to be defined on the given named property.\n * If no descriptor is returned, the property will not become an accessor.\n * For example,\n *\n * class MyElement extends LitElement {\n * static getPropertyDescriptor(name, key, options) {\n * const defaultDescriptor =\n * super.getPropertyDescriptor(name, key, options);\n * const setter = defaultDescriptor.set;\n * return {\n * get: defaultDescriptor.get,\n * set(value) {\n * setter.call(this, value);\n * // custom action.\n * },\n * configurable: true,\n * enumerable: true\n * }\n * }\n * }\n *\n * @nocollapse\n */\n static getPropertyDescriptor(name, key, _options) {\n return {\n // tslint:disable-next-line:no-any no symbol in index\n get() {\n return this[key];\n },\n set(value) {\n const oldValue = this[name];\n this[key] = value;\n this._requestUpdate(name, oldValue);\n },\n configurable: true,\n enumerable: true\n };\n }\n /**\n * Returns the property options associated with the given property.\n * These options are defined with a PropertyDeclaration via the `properties`\n * object or the `@property` decorator and are registered in\n * `createProperty(...)`.\n *\n * Note, this method should be considered \"final\" and not overridden. To\n * customize the options for a given property, override `createProperty`.\n *\n * @nocollapse\n * @final\n */\n static getPropertyOptions(name) {\n return this._classProperties && this._classProperties.get(name) ||\n defaultPropertyDeclaration;\n }\n /**\n * Creates property accessors for registered properties and ensures\n * any superclasses are also finalized.\n * @nocollapse\n */\n static finalize() {\n // finalize any superclasses\n const superCtor = Object.getPrototypeOf(this);\n if (!superCtor.hasOwnProperty(finalized)) {\n superCtor.finalize();\n }\n this[finalized] = true;\n this._ensureClassProperties();\n // initialize Map populated in observedAttributes\n this._attributeToPropertyMap = new Map();\n // make any properties\n // Note, only process \"own\" properties since this element will inherit\n // any properties defined on the superClass, and finalization ensures\n // the entire prototype chain is finalized.\n if (this.hasOwnProperty(JSCompiler_renameProperty('properties', this))) {\n const props = this.properties;\n // support symbols in properties (IE11 does not support this)\n const propKeys = [\n ...Object.getOwnPropertyNames(props),\n ...(typeof Object.getOwnPropertySymbols === 'function') ?\n Object.getOwnPropertySymbols(props) :\n []\n ];\n // This for/of is ok because propKeys is an array\n for (const p of propKeys) {\n // note, use of `any` is due to TypeSript lack of support for symbol in\n // index types\n // tslint:disable-next-line:no-any no symbol in index\n this.createProperty(p, props[p]);\n }\n }\n }\n /**\n * Returns the property name for the given attribute `name`.\n * @nocollapse\n */\n static _attributeNameForProperty(name, options) {\n const attribute = options.attribute;\n return attribute === false ?\n undefined :\n (typeof attribute === 'string' ?\n attribute :\n (typeof name === 'string' ? name.toLowerCase() : undefined));\n }\n /**\n * Returns true if a property should request an update.\n * Called when a property value is set and uses the `hasChanged`\n * option for the property if present or a strict identity check.\n * @nocollapse\n */\n static _valueHasChanged(value, old, hasChanged = notEqual) {\n return hasChanged(value, old);\n }\n /**\n * Returns the property value for the given attribute value.\n * Called via the `attributeChangedCallback` and uses the property's\n * `converter` or `converter.fromAttribute` property option.\n * @nocollapse\n */\n static _propertyValueFromAttribute(value, options) {\n const type = options.type;\n const converter = options.converter || defaultConverter;\n const fromAttribute = (typeof converter === 'function' ? converter : converter.fromAttribute);\n return fromAttribute ? fromAttribute(value, type) : value;\n }\n /**\n * Returns the attribute value for the given property value. If this\n * returns undefined, the property will *not* be reflected to an attribute.\n * If this returns null, the attribute will be removed, otherwise the\n * attribute will be set to the value.\n * This uses the property's `reflect` and `type.toAttribute` property options.\n * @nocollapse\n */\n static _propertyValueToAttribute(value, options) {\n if (options.reflect === undefined) {\n return;\n }\n const type = options.type;\n const converter = options.converter;\n const toAttribute = converter && converter.toAttribute ||\n defaultConverter.toAttribute;\n return toAttribute(value, type);\n }\n /**\n * Performs element initialization. By default captures any pre-set values for\n * registered properties.\n */\n initialize() {\n this._saveInstanceProperties();\n // ensures first update will be caught by an early access of\n // `updateComplete`\n this._requestUpdate();\n }\n /**\n * Fixes any properties set on the instance before upgrade time.\n * Otherwise these would shadow the accessor and break these properties.\n * The properties are stored in a Map which is played back after the\n * constructor runs. Note, on very old versions of Safari (<=9) or Chrome\n * (<=41), properties created for native platform properties like (`id` or\n * `name`) may not have default values set in the element constructor. On\n * these browsers native properties appear on instances and therefore their\n * default value will overwrite any element default (e.g. if the element sets\n * this.id = 'id' in the constructor, the 'id' will become '' since this is\n * the native platform default).\n */\n _saveInstanceProperties() {\n // Use forEach so this works even if for/of loops are compiled to for loops\n // expecting arrays\n this.constructor\n ._classProperties.forEach((_v, p) => {\n if (this.hasOwnProperty(p)) {\n const value = this[p];\n delete this[p];\n if (!this._instanceProperties) {\n this._instanceProperties = new Map();\n }\n this._instanceProperties.set(p, value);\n }\n });\n }\n /**\n * Applies previously saved instance properties.\n */\n _applyInstanceProperties() {\n // Use forEach so this works even if for/of loops are compiled to for loops\n // expecting arrays\n // tslint:disable-next-line:no-any\n this._instanceProperties.forEach((v, p) => this[p] = v);\n this._instanceProperties = undefined;\n }\n connectedCallback() {\n // Ensure first connection completes an update. Updates cannot complete\n // before connection.\n this.enableUpdating();\n }\n enableUpdating() {\n if (this._enableUpdatingResolver !== undefined) {\n this._enableUpdatingResolver();\n this._enableUpdatingResolver = undefined;\n }\n }\n /**\n * Allows for `super.disconnectedCallback()` in extensions while\n * reserving the possibility of making non-breaking feature additions\n * when disconnecting at some point in the future.\n */\n disconnectedCallback() {\n }\n /**\n * Synchronizes property values when attributes change.\n */\n attributeChangedCallback(name, old, value) {\n if (old !== value) {\n this._attributeToProperty(name, value);\n }\n }\n _propertyToAttribute(name, value, options = defaultPropertyDeclaration) {\n const ctor = this.constructor;\n const attr = ctor._attributeNameForProperty(name, options);\n if (attr !== undefined) {\n const attrValue = ctor._propertyValueToAttribute(value, options);\n // an undefined value does not change the attribute.\n if (attrValue === undefined) {\n return;\n }\n // Track if the property is being reflected to avoid\n // setting the property again via `attributeChangedCallback`. Note:\n // 1. this takes advantage of the fact that the callback is synchronous.\n // 2. will behave incorrectly if multiple attributes are in the reaction\n // stack at time of calling. However, since we process attributes\n // in `update` this should not be possible (or an extreme corner case\n // that we'd like to discover).\n // mark state reflecting\n this._updateState = this._updateState | STATE_IS_REFLECTING_TO_ATTRIBUTE;\n if (attrValue == null) {\n this.removeAttribute(attr);\n }\n else {\n this.setAttribute(attr, attrValue);\n }\n // mark state not reflecting\n this._updateState = this._updateState & ~STATE_IS_REFLECTING_TO_ATTRIBUTE;\n }\n }\n _attributeToProperty(name, value) {\n // Use tracking info to avoid deserializing attribute value if it was\n // just set from a property setter.\n if (this._updateState & STATE_IS_REFLECTING_TO_ATTRIBUTE) {\n return;\n }\n const ctor = this.constructor;\n // Note, hint this as an `AttributeMap` so closure clearly understands\n // the type; it has issues with tracking types through statics\n // tslint:disable-next-line:no-unnecessary-type-assertion\n const propName = ctor._attributeToPropertyMap.get(name);\n if (propName !== undefined) {\n const options = ctor.getPropertyOptions(propName);\n // mark state reflecting\n this._updateState = this._updateState | STATE_IS_REFLECTING_TO_PROPERTY;\n this[propName] =\n // tslint:disable-next-line:no-any\n ctor._propertyValueFromAttribute(value, options);\n // mark state not reflecting\n this._updateState = this._updateState & ~STATE_IS_REFLECTING_TO_PROPERTY;\n }\n }\n /**\n * This private version of `requestUpdate` does not access or return the\n * `updateComplete` promise. This promise can be overridden and is therefore\n * not free to access.\n */\n _requestUpdate(name, oldValue) {\n let shouldRequestUpdate = true;\n // If we have a property key, perform property update steps.\n if (name !== undefined) {\n const ctor = this.constructor;\n const options = ctor.getPropertyOptions(name);\n if (ctor._valueHasChanged(this[name], oldValue, options.hasChanged)) {\n if (!this._changedProperties.has(name)) {\n this._changedProperties.set(name, oldValue);\n }\n // Add to reflecting properties set.\n // Note, it's important that every change has a chance to add the\n // property to `_reflectingProperties`. This ensures setting\n // attribute + property reflects correctly.\n if (options.reflect === true &&\n !(this._updateState & STATE_IS_REFLECTING_TO_PROPERTY)) {\n if (this._reflectingProperties === undefined) {\n this._reflectingProperties = new Map();\n }\n this._reflectingProperties.set(name, options);\n }\n }\n else {\n // Abort the request if the property should not be considered changed.\n shouldRequestUpdate = false;\n }\n }\n if (!this._hasRequestedUpdate && shouldRequestUpdate) {\n this._updatePromise = this._enqueueUpdate();\n }\n }\n /**\n * Requests an update which is processed asynchronously. This should\n * be called when an element should update based on some state not triggered\n * by setting a property. In this case, pass no arguments. It should also be\n * called when manually implementing a property setter. In this case, pass the\n * property `name` and `oldValue` to ensure that any configured property\n * options are honored. Returns the `updateComplete` Promise which is resolved\n * when the update completes.\n *\n * @param name {PropertyKey} (optional) name of requesting property\n * @param oldValue {any} (optional) old value of requesting property\n * @returns {Promise} A Promise that is resolved when the update completes.\n */\n requestUpdate(name, oldValue) {\n this._requestUpdate(name, oldValue);\n return this.updateComplete;\n }\n /**\n * Sets up the element to asynchronously update.\n */\n async _enqueueUpdate() {\n this._updateState = this._updateState | STATE_UPDATE_REQUESTED;\n try {\n // Ensure any previous update has resolved before updating.\n // This `await` also ensures that property changes are batched.\n await this._updatePromise;\n }\n catch (e) {\n // Ignore any previous errors. We only care that the previous cycle is\n // done. Any error should have been handled in the previous update.\n }\n const result = this.performUpdate();\n // If `performUpdate` returns a Promise, we await it. This is done to\n // enable coordinating updates with a scheduler. Note, the result is\n // checked to avoid delaying an additional microtask unless we need to.\n if (result != null) {\n await result;\n }\n return !this._hasRequestedUpdate;\n }\n get _hasRequestedUpdate() {\n return (this._updateState & STATE_UPDATE_REQUESTED);\n }\n get hasUpdated() {\n return (this._updateState & STATE_HAS_UPDATED);\n }\n /**\n * Performs an element update. Note, if an exception is thrown during the\n * update, `firstUpdated` and `updated` will not be called.\n *\n * You can override this method to change the timing of updates. If this\n * method is overridden, `super.performUpdate()` must be called.\n *\n * For instance, to schedule updates to occur just before the next frame:\n *\n * ```\n * protected async performUpdate(): Promise<unknown> {\n * await new Promise((resolve) => requestAnimationFrame(() => resolve()));\n * super.performUpdate();\n * }\n * ```\n */\n performUpdate() {\n // Mixin instance properties once, if they exist.\n if (this._instanceProperties) {\n this._applyInstanceProperties();\n }\n let shouldUpdate = false;\n const changedProperties = this._changedProperties;\n try {\n shouldUpdate = this.shouldUpdate(changedProperties);\n if (shouldUpdate) {\n this.update(changedProperties);\n }\n else {\n this._markUpdated();\n }\n }\n catch (e) {\n // Prevent `firstUpdated` and `updated` from running when there's an\n // update exception.\n shouldUpdate = false;\n // Ensure element can accept additional updates after an exception.\n this._markUpdated();\n throw e;\n }\n if (shouldUpdate) {\n if (!(this._updateState & STATE_HAS_UPDATED)) {\n this._updateState = this._updateState | STATE_HAS_UPDATED;\n this.firstUpdated(changedProperties);\n }\n this.updated(changedProperties);\n }\n }\n _markUpdated() {\n this._changedProperties = new Map();\n this._updateState = this._updateState & ~STATE_UPDATE_REQUESTED;\n }\n /**\n * Returns a Promise that resolves when the element has completed updating.\n * The Promise value is a boolean that is `true` if the element completed the\n * update without triggering another update. The Promise result is `false` if\n * a property was set inside `updated()`. If the Promise is rejected, an\n * exception was thrown during the update.\n *\n * To await additional asynchronous work, override the `_getUpdateComplete`\n * method. For example, it is sometimes useful to await a rendered element\n * before fulfilling this Promise. To do this, first await\n * `super._getUpdateComplete()`, then any subsequent state.\n *\n * @returns {Promise} The Promise returns a boolean that indicates if the\n * update resolved without triggering another update.\n */\n get updateComplete() {\n return this._getUpdateComplete();\n }\n /**\n * Override point for the `updateComplete` promise.\n *\n * It is not safe to override the `updateComplete` getter directly due to a\n * limitation in TypeScript which means it is not possible to call a\n * superclass getter (e.g. `super.updateComplete.then(...)`) when the target\n * language is ES5 (https://github.com/microsoft/TypeScript/issues/338).\n * This method should be overridden instead. For example:\n *\n * class MyElement extends LitElement {\n * async _getUpdateComplete() {\n * await super._getUpdateComplete();\n * await this._myChild.updateComplete;\n * }\n * }\n */\n _getUpdateComplete() {\n return this._updatePromise;\n }\n /**\n * Controls whether or not `update` should be called when the element requests\n * an update. By default, this method always returns `true`, but this can be\n * customized to control when to update.\n *\n * @param _changedProperties Map of changed properties with old values\n */\n shouldUpdate(_changedProperties) {\n return true;\n }\n /**\n * Updates the element. This method reflects property values to attributes.\n * It can be overridden to render and keep updated element DOM.\n * Setting properties inside this method will *not* trigger\n * another update.\n *\n * @param _changedProperties Map of changed properties with old values\n */\n update(_changedProperties) {\n if (this._reflectingProperties !== undefined &&\n this._reflectingProperties.size > 0) {\n // Use forEach so this works even if for/of loops are compiled to for\n // loops expecting arrays\n this._reflectingProperties.forEach((v, k) => this._propertyToAttribute(k, this[k], v));\n this._reflectingProperties = undefined;\n }\n this._markUpdated();\n }\n /**\n * Invoked whenever the element is updated. Implement to perform\n * post-updating tasks via DOM APIs, for example, focusing an element.\n *\n * Setting properties inside this method will trigger the element to update\n * again after this update cycle completes.\n *\n * @param _changedProperties Map of changed properties with old values\n */\n updated(_changedProperties) {\n }\n /**\n * Invoked when the element is first updated. Implement to perform one time\n * work on the element after update.\n *\n * Setting properties inside this method will trigger the element to update\n * again after this update cycle completes.\n *\n * @param _changedProperties Map of changed properties with old values\n */\n firstUpdated(_changedProperties) {\n }\n}\n_a = finalized;\n/**\n * Marks class as having finished creating properties.\n */\nUpdatingElement[_a] = true;\n//# sourceMappingURL=updating-element.js.map\n\n//# sourceURL=webpack:///./node_modules/lit-element/lib/updating-element.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/lit-element/lit-element.js":
|
|
/*!*************************************************!*\
|
|
!*** ./node_modules/lit-element/lit-element.js ***!
|
|
\*************************************************/
|
|
/*! exports provided: defaultConverter, notEqual, UpdatingElement, customElement, property, internalProperty, query, queryAsync, queryAll, eventOptions, queryAssignedNodes, html, svg, TemplateResult, SVGTemplateResult, supportsAdoptingStyleSheets, CSSResult, unsafeCSS, css, LitElement */
|
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"LitElement\", function() { return LitElement; });\n/* harmony import */ var lit_html_lib_shady_render_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! lit-html/lib/shady-render.js */ \"./node_modules/lit-element/node_modules/lit-html/lib/shady-render.js\");\n/* harmony import */ var _lib_updating_element_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./lib/updating-element.js */ \"./node_modules/lit-element/lib/updating-element.js\");\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"defaultConverter\", function() { return _lib_updating_element_js__WEBPACK_IMPORTED_MODULE_1__[\"defaultConverter\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"notEqual\", function() { return _lib_updating_element_js__WEBPACK_IMPORTED_MODULE_1__[\"notEqual\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"UpdatingElement\", function() { return _lib_updating_element_js__WEBPACK_IMPORTED_MODULE_1__[\"UpdatingElement\"]; });\n\n/* harmony import */ var _lib_decorators_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./lib/decorators.js */ \"./node_modules/lit-element/lib/decorators.js\");\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"customElement\", function() { return _lib_decorators_js__WEBPACK_IMPORTED_MODULE_2__[\"customElement\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"property\", function() { return _lib_decorators_js__WEBPACK_IMPORTED_MODULE_2__[\"property\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"internalProperty\", function() { return _lib_decorators_js__WEBPACK_IMPORTED_MODULE_2__[\"internalProperty\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"query\", function() { return _lib_decorators_js__WEBPACK_IMPORTED_MODULE_2__[\"query\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"queryAsync\", function() { return _lib_decorators_js__WEBPACK_IMPORTED_MODULE_2__[\"queryAsync\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"queryAll\", function() { return _lib_decorators_js__WEBPACK_IMPORTED_MODULE_2__[\"queryAll\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"eventOptions\", function() { return _lib_decorators_js__WEBPACK_IMPORTED_MODULE_2__[\"eventOptions\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"queryAssignedNodes\", function() { return _lib_decorators_js__WEBPACK_IMPORTED_MODULE_2__[\"queryAssignedNodes\"]; });\n\n/* harmony import */ var lit_html_lit_html_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! lit-html/lit-html.js */ \"./node_modules/lit-element/node_modules/lit-html/lit-html.js\");\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"html\", function() { return lit_html_lit_html_js__WEBPACK_IMPORTED_MODULE_3__[\"html\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"svg\", function() { return lit_html_lit_html_js__WEBPACK_IMPORTED_MODULE_3__[\"svg\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"TemplateResult\", function() { return lit_html_lit_html_js__WEBPACK_IMPORTED_MODULE_3__[\"TemplateResult\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"SVGTemplateResult\", function() { return lit_html_lit_html_js__WEBPACK_IMPORTED_MODULE_3__[\"SVGTemplateResult\"]; });\n\n/* harmony import */ var _lib_css_tag_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./lib/css-tag.js */ \"./node_modules/lit-element/lib/css-tag.js\");\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"supportsAdoptingStyleSheets\", function() { return _lib_css_tag_js__WEBPACK_IMPORTED_MODULE_4__[\"supportsAdoptingStyleSheets\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"CSSResult\", function() { return _lib_css_tag_js__WEBPACK_IMPORTED_MODULE_4__[\"CSSResult\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"unsafeCSS\", function() { return _lib_css_tag_js__WEBPACK_IMPORTED_MODULE_4__[\"unsafeCSS\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"css\", function() { return _lib_css_tag_js__WEBPACK_IMPORTED_MODULE_4__[\"css\"]; });\n\n/**\n * @license\n * Copyright (c) 2017 The Polymer Project Authors. All rights reserved.\n * This code may only be used under the BSD style license found at\n * http://polymer.github.io/LICENSE.txt\n * The complete set of authors may be found at\n * http://polymer.github.io/AUTHORS.txt\n * The complete set of contributors may be found at\n * http://polymer.github.io/CONTRIBUTORS.txt\n * Code distributed by Google as part of the polymer project is also\n * subject to an additional IP rights grant found at\n * http://polymer.github.io/PATENTS.txt\n */\n\n\n\n\n\n\n\n// IMPORTANT: do not change the property name or the assignment expression.\n// This line will be used in regexes to search for LitElement usage.\n// TODO(justinfagnani): inject version number at build time\n(window['litElementVersions'] || (window['litElementVersions'] = []))\n .push('2.3.1');\n/**\n * Sentinal value used to avoid calling lit-html's render function when\n * subclasses do not implement `render`\n */\nconst renderNotImplemented = {};\nclass LitElement extends _lib_updating_element_js__WEBPACK_IMPORTED_MODULE_1__[\"UpdatingElement\"] {\n /**\n * Return the array of styles to apply to the element.\n * Override this method to integrate into a style management system.\n *\n * @nocollapse\n */\n static getStyles() {\n return this.styles;\n }\n /** @nocollapse */\n static _getUniqueStyles() {\n // Only gather styles once per class\n if (this.hasOwnProperty(JSCompiler_renameProperty('_styles', this))) {\n return;\n }\n // Take care not to call `this.getStyles()` multiple times since this\n // generates new CSSResults each time.\n // TODO(sorvell): Since we do not cache CSSResults by input, any\n // shared styles will generate new stylesheet objects, which is wasteful.\n // This should be addressed when a browser ships constructable\n // stylesheets.\n const userStyles = this.getStyles();\n if (userStyles === undefined) {\n this._styles = [];\n }\n else if (Array.isArray(userStyles)) {\n // De-duplicate styles preserving the _last_ instance in the set.\n // This is a performance optimization to avoid duplicated styles that can\n // occur especially when composing via subclassing.\n // The last item is kept to try to preserve the cascade order with the\n // assumption that it's most important that last added styles override\n // previous styles.\n const addStyles = (styles, set) => styles.reduceRight((set, s) => \n // Note: On IE set.add() does not return the set\n Array.isArray(s) ? addStyles(s, set) : (set.add(s), set), set);\n // Array.from does not work on Set in IE, otherwise return\n // Array.from(addStyles(userStyles, new Set<CSSResult>())).reverse()\n const set = addStyles(userStyles, new Set());\n const styles = [];\n set.forEach((v) => styles.unshift(v));\n this._styles = styles;\n }\n else {\n this._styles = [userStyles];\n }\n }\n /**\n * Performs element initialization. By default this calls `createRenderRoot`\n * to create the element `renderRoot` node and captures any pre-set values for\n * registered properties.\n */\n initialize() {\n super.initialize();\n this.constructor._getUniqueStyles();\n this.renderRoot =\n this.createRenderRoot();\n // Note, if renderRoot is not a shadowRoot, styles would/could apply to the\n // element's getRootNode(). While this could be done, we're choosing not to\n // support this now since it would require different logic around de-duping.\n if (window.ShadowRoot && this.renderRoot instanceof window.ShadowRoot) {\n this.adoptStyles();\n }\n }\n /**\n * Returns the node into which the element should render and by default\n * creates and returns an open shadowRoot. Implement to customize where the\n * element's DOM is rendered. For example, to render into the element's\n * childNodes, return `this`.\n * @returns {Element|DocumentFragment} Returns a node into which to render.\n */\n createRenderRoot() {\n return this.attachShadow({ mode: 'open' });\n }\n /**\n * Applies styling to the element shadowRoot using the `static get styles`\n * property. Styling will apply using `shadowRoot.adoptedStyleSheets` where\n * available and will fallback otherwise. When Shadow DOM is polyfilled,\n * ShadyCSS scopes styles and adds them to the document. When Shadow DOM\n * is available but `adoptedStyleSheets` is not, styles are appended to the\n * end of the `shadowRoot` to [mimic spec\n * behavior](https://wicg.github.io/construct-stylesheets/#using-constructed-stylesheets).\n */\n adoptStyles() {\n const styles = this.constructor._styles;\n if (styles.length === 0) {\n return;\n }\n // There are three separate cases here based on Shadow DOM support.\n // (1) shadowRoot polyfilled: use ShadyCSS\n // (2) shadowRoot.adoptedStyleSheets available: use it.\n // (3) shadowRoot.adoptedStyleSheets polyfilled: append styles after\n // rendering\n if (window.ShadyCSS !== undefined && !window.ShadyCSS.nativeShadow) {\n window.ShadyCSS.ScopingShim.prepareAdoptedCssText(styles.map((s) => s.cssText), this.localName);\n }\n else if (_lib_css_tag_js__WEBPACK_IMPORTED_MODULE_4__[\"supportsAdoptingStyleSheets\"]) {\n this.renderRoot.adoptedStyleSheets =\n styles.map((s) => s.styleSheet);\n }\n else {\n // This must be done after rendering so the actual style insertion is done\n // in `update`.\n this._needsShimAdoptedStyleSheets = true;\n }\n }\n connectedCallback() {\n super.connectedCallback();\n // Note, first update/render handles styleElement so we only call this if\n // connected after first update.\n if (this.hasUpdated && window.ShadyCSS !== undefined) {\n window.ShadyCSS.styleElement(this);\n }\n }\n /**\n * Updates the element. This method reflects property values to attributes\n * and calls `render` to render DOM via lit-html. Setting properties inside\n * this method will *not* trigger another update.\n * @param _changedProperties Map of changed properties with old values\n */\n update(changedProperties) {\n // Setting properties in `render` should not trigger an update. Since\n // updates are allowed after super.update, it's important to call `render`\n // before that.\n const templateResult = this.render();\n super.update(changedProperties);\n // If render is not implemented by the component, don't call lit-html render\n if (templateResult !== renderNotImplemented) {\n this.constructor\n .render(templateResult, this.renderRoot, { scopeName: this.localName, eventContext: this });\n }\n // When native Shadow DOM is used but adoptedStyles are not supported,\n // insert styling after rendering to ensure adoptedStyles have highest\n // priority.\n if (this._needsShimAdoptedStyleSheets) {\n this._needsShimAdoptedStyleSheets = false;\n this.constructor._styles.forEach((s) => {\n const style = document.createElement('style');\n style.textContent = s.cssText;\n this.renderRoot.appendChild(style);\n });\n }\n }\n /**\n * Invoked on each update to perform rendering tasks. This method may return\n * any value renderable by lit-html's NodePart - typically a TemplateResult.\n * Setting properties inside this method will *not* trigger the element to\n * update.\n */\n render() {\n return renderNotImplemented;\n }\n}\n/**\n * Ensure this class is marked as `finalized` as an optimization ensuring\n * it will not needlessly try to `finalize`.\n *\n * Note this property name is a string to prevent breaking Closure JS Compiler\n * optimizations. See updating-element.ts for more information.\n */\nLitElement['finalized'] = true;\n/**\n * Render method used to render the value to the element's DOM.\n * @param result The value to render.\n * @param container Node into which to render.\n * @param options Element name.\n * @nocollapse\n */\nLitElement.render = lit_html_lib_shady_render_js__WEBPACK_IMPORTED_MODULE_0__[\"render\"];\n//# sourceMappingURL=lit-element.js.map\n\n//# sourceURL=webpack:///./node_modules/lit-element/lit-element.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/lit-element/node_modules/lit-html/lib/default-template-processor.js":
|
|
/*!******************************************************************************************!*\
|
|
!*** ./node_modules/lit-element/node_modules/lit-html/lib/default-template-processor.js ***!
|
|
\******************************************************************************************/
|
|
/*! exports provided: DefaultTemplateProcessor, defaultTemplateProcessor */
|
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"DefaultTemplateProcessor\", function() { return DefaultTemplateProcessor; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"defaultTemplateProcessor\", function() { return defaultTemplateProcessor; });\n/* harmony import */ var _parts_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./parts.js */ \"./node_modules/lit-element/node_modules/lit-html/lib/parts.js\");\n/**\n * @license\n * Copyright (c) 2017 The Polymer Project Authors. All rights reserved.\n * This code may only be used under the BSD style license found at\n * http://polymer.github.io/LICENSE.txt\n * The complete set of authors may be found at\n * http://polymer.github.io/AUTHORS.txt\n * The complete set of contributors may be found at\n * http://polymer.github.io/CONTRIBUTORS.txt\n * Code distributed by Google as part of the polymer project is also\n * subject to an additional IP rights grant found at\n * http://polymer.github.io/PATENTS.txt\n */\n\n/**\n * Creates Parts when a template is instantiated.\n */\nclass DefaultTemplateProcessor {\n /**\n * Create parts for an attribute-position binding, given the event, attribute\n * name, and string literals.\n *\n * @param element The element containing the binding\n * @param name The attribute name\n * @param strings The string literals. There are always at least two strings,\n * event for fully-controlled bindings with a single expression.\n */\n handleAttributeExpressions(element, name, strings, options) {\n const prefix = name[0];\n if (prefix === '.') {\n const committer = new _parts_js__WEBPACK_IMPORTED_MODULE_0__[\"PropertyCommitter\"](element, name.slice(1), strings);\n return committer.parts;\n }\n if (prefix === '@') {\n return [new _parts_js__WEBPACK_IMPORTED_MODULE_0__[\"EventPart\"](element, name.slice(1), options.eventContext)];\n }\n if (prefix === '?') {\n return [new _parts_js__WEBPACK_IMPORTED_MODULE_0__[\"BooleanAttributePart\"](element, name.slice(1), strings)];\n }\n const committer = new _parts_js__WEBPACK_IMPORTED_MODULE_0__[\"AttributeCommitter\"](element, name, strings);\n return committer.parts;\n }\n /**\n * Create parts for a text-position binding.\n * @param templateFactory\n */\n handleTextExpression(options) {\n return new _parts_js__WEBPACK_IMPORTED_MODULE_0__[\"NodePart\"](options);\n }\n}\nconst defaultTemplateProcessor = new DefaultTemplateProcessor();\n//# sourceMappingURL=default-template-processor.js.map\n\n//# sourceURL=webpack:///./node_modules/lit-element/node_modules/lit-html/lib/default-template-processor.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/lit-element/node_modules/lit-html/lib/directive.js":
|
|
/*!*************************************************************************!*\
|
|
!*** ./node_modules/lit-element/node_modules/lit-html/lib/directive.js ***!
|
|
\*************************************************************************/
|
|
/*! exports provided: directive, isDirective */
|
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"directive\", function() { return directive; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"isDirective\", function() { return isDirective; });\n/**\n * @license\n * Copyright (c) 2017 The Polymer Project Authors. All rights reserved.\n * This code may only be used under the BSD style license found at\n * http://polymer.github.io/LICENSE.txt\n * The complete set of authors may be found at\n * http://polymer.github.io/AUTHORS.txt\n * The complete set of contributors may be found at\n * http://polymer.github.io/CONTRIBUTORS.txt\n * Code distributed by Google as part of the polymer project is also\n * subject to an additional IP rights grant found at\n * http://polymer.github.io/PATENTS.txt\n */\nconst directives = new WeakMap();\n/**\n * Brands a function as a directive factory function so that lit-html will call\n * the function during template rendering, rather than passing as a value.\n *\n * A _directive_ is a function that takes a Part as an argument. It has the\n * signature: `(part: Part) => void`.\n *\n * A directive _factory_ is a function that takes arguments for data and\n * configuration and returns a directive. Users of directive usually refer to\n * the directive factory as the directive. For example, \"The repeat directive\".\n *\n * Usually a template author will invoke a directive factory in their template\n * with relevant arguments, which will then return a directive function.\n *\n * Here's an example of using the `repeat()` directive factory that takes an\n * array and a function to render an item:\n *\n * ```js\n * html`<ul><${repeat(items, (item) => html`<li>${item}</li>`)}</ul>`\n * ```\n *\n * When `repeat` is invoked, it returns a directive function that closes over\n * `items` and the template function. When the outer template is rendered, the\n * return directive function is called with the Part for the expression.\n * `repeat` then performs it's custom logic to render multiple items.\n *\n * @param f The directive factory function. Must be a function that returns a\n * function of the signature `(part: Part) => void`. The returned function will\n * be called with the part object.\n *\n * @example\n *\n * import {directive, html} from 'lit-html';\n *\n * const immutable = directive((v) => (part) => {\n * if (part.value !== v) {\n * part.setValue(v)\n * }\n * });\n */\nconst directive = (f) => ((...args) => {\n const d = f(...args);\n directives.set(d, true);\n return d;\n});\nconst isDirective = (o) => {\n return typeof o === 'function' && directives.has(o);\n};\n//# sourceMappingURL=directive.js.map\n\n//# sourceURL=webpack:///./node_modules/lit-element/node_modules/lit-html/lib/directive.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/lit-element/node_modules/lit-html/lib/dom.js":
|
|
/*!*******************************************************************!*\
|
|
!*** ./node_modules/lit-element/node_modules/lit-html/lib/dom.js ***!
|
|
\*******************************************************************/
|
|
/*! exports provided: isCEPolyfill, reparentNodes, removeNodes */
|
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"isCEPolyfill\", function() { return isCEPolyfill; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"reparentNodes\", function() { return reparentNodes; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"removeNodes\", function() { return removeNodes; });\n/**\n * @license\n * Copyright (c) 2017 The Polymer Project Authors. All rights reserved.\n * This code may only be used under the BSD style license found at\n * http://polymer.github.io/LICENSE.txt\n * The complete set of authors may be found at\n * http://polymer.github.io/AUTHORS.txt\n * The complete set of contributors may be found at\n * http://polymer.github.io/CONTRIBUTORS.txt\n * Code distributed by Google as part of the polymer project is also\n * subject to an additional IP rights grant found at\n * http://polymer.github.io/PATENTS.txt\n */\n/**\n * True if the custom elements polyfill is in use.\n */\nconst isCEPolyfill = typeof window !== 'undefined' &&\n window.customElements != null &&\n window.customElements.polyfillWrapFlushCallback !==\n undefined;\n/**\n * Reparents nodes, starting from `start` (inclusive) to `end` (exclusive),\n * into another container (could be the same container), before `before`. If\n * `before` is null, it appends the nodes to the container.\n */\nconst reparentNodes = (container, start, end = null, before = null) => {\n while (start !== end) {\n const n = start.nextSibling;\n container.insertBefore(start, before);\n start = n;\n }\n};\n/**\n * Removes nodes, starting from `start` (inclusive) to `end` (exclusive), from\n * `container`.\n */\nconst removeNodes = (container, start, end = null) => {\n while (start !== end) {\n const n = start.nextSibling;\n container.removeChild(start);\n start = n;\n }\n};\n//# sourceMappingURL=dom.js.map\n\n//# sourceURL=webpack:///./node_modules/lit-element/node_modules/lit-html/lib/dom.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/lit-element/node_modules/lit-html/lib/modify-template.js":
|
|
/*!*******************************************************************************!*\
|
|
!*** ./node_modules/lit-element/node_modules/lit-html/lib/modify-template.js ***!
|
|
\*******************************************************************************/
|
|
/*! exports provided: removeNodesFromTemplate, insertNodeIntoTemplate */
|
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"removeNodesFromTemplate\", function() { return removeNodesFromTemplate; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"insertNodeIntoTemplate\", function() { return insertNodeIntoTemplate; });\n/* harmony import */ var _template_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./template.js */ \"./node_modules/lit-element/node_modules/lit-html/lib/template.js\");\n/**\n * @license\n * Copyright (c) 2017 The Polymer Project Authors. All rights reserved.\n * This code may only be used under the BSD style license found at\n * http://polymer.github.io/LICENSE.txt\n * The complete set of authors may be found at\n * http://polymer.github.io/AUTHORS.txt\n * The complete set of contributors may be found at\n * http://polymer.github.io/CONTRIBUTORS.txt\n * Code distributed by Google as part of the polymer project is also\n * subject to an additional IP rights grant found at\n * http://polymer.github.io/PATENTS.txt\n */\n/**\n * @module shady-render\n */\n\nconst walkerNodeFilter = 133 /* NodeFilter.SHOW_{ELEMENT|COMMENT|TEXT} */;\n/**\n * Removes the list of nodes from a Template safely. In addition to removing\n * nodes from the Template, the Template part indices are updated to match\n * the mutated Template DOM.\n *\n * As the template is walked the removal state is tracked and\n * part indices are adjusted as needed.\n *\n * div\n * div#1 (remove) <-- start removing (removing node is div#1)\n * div\n * div#2 (remove) <-- continue removing (removing node is still div#1)\n * div\n * div <-- stop removing since previous sibling is the removing node (div#1,\n * removed 4 nodes)\n */\nfunction removeNodesFromTemplate(template, nodesToRemove) {\n const { element: { content }, parts } = template;\n const walker = document.createTreeWalker(content, walkerNodeFilter, null, false);\n let partIndex = nextActiveIndexInTemplateParts(parts);\n let part = parts[partIndex];\n let nodeIndex = -1;\n let removeCount = 0;\n const nodesToRemoveInTemplate = [];\n let currentRemovingNode = null;\n while (walker.nextNode()) {\n nodeIndex++;\n const node = walker.currentNode;\n // End removal if stepped past the removing node\n if (node.previousSibling === currentRemovingNode) {\n currentRemovingNode = null;\n }\n // A node to remove was found in the template\n if (nodesToRemove.has(node)) {\n nodesToRemoveInTemplate.push(node);\n // Track node we're removing\n if (currentRemovingNode === null) {\n currentRemovingNode = node;\n }\n }\n // When removing, increment count by which to adjust subsequent part indices\n if (currentRemovingNode !== null) {\n removeCount++;\n }\n while (part !== undefined && part.index === nodeIndex) {\n // If part is in a removed node deactivate it by setting index to -1 or\n // adjust the index as needed.\n part.index = currentRemovingNode !== null ? -1 : part.index - removeCount;\n // go to the next active part.\n partIndex = nextActiveIndexInTemplateParts(parts, partIndex);\n part = parts[partIndex];\n }\n }\n nodesToRemoveInTemplate.forEach((n) => n.parentNode.removeChild(n));\n}\nconst countNodes = (node) => {\n let count = (node.nodeType === 11 /* Node.DOCUMENT_FRAGMENT_NODE */) ? 0 : 1;\n const walker = document.createTreeWalker(node, walkerNodeFilter, null, false);\n while (walker.nextNode()) {\n count++;\n }\n return count;\n};\nconst nextActiveIndexInTemplateParts = (parts, startIndex = -1) => {\n for (let i = startIndex + 1; i < parts.length; i++) {\n const part = parts[i];\n if (Object(_template_js__WEBPACK_IMPORTED_MODULE_0__[\"isTemplatePartActive\"])(part)) {\n return i;\n }\n }\n return -1;\n};\n/**\n * Inserts the given node into the Template, optionally before the given\n * refNode. In addition to inserting the node into the Template, the Template\n * part indices are updated to match the mutated Template DOM.\n */\nfunction insertNodeIntoTemplate(template, node, refNode = null) {\n const { element: { content }, parts } = template;\n // If there's no refNode, then put node at end of template.\n // No part indices need to be shifted in this case.\n if (refNode === null || refNode === undefined) {\n content.appendChild(node);\n return;\n }\n const walker = document.createTreeWalker(content, walkerNodeFilter, null, false);\n let partIndex = nextActiveIndexInTemplateParts(parts);\n let insertCount = 0;\n let walkerIndex = -1;\n while (walker.nextNode()) {\n walkerIndex++;\n const walkerNode = walker.currentNode;\n if (walkerNode === refNode) {\n insertCount = countNodes(node);\n refNode.parentNode.insertBefore(node, refNode);\n }\n while (partIndex !== -1 && parts[partIndex].index === walkerIndex) {\n // If we've inserted the node, simply adjust all subsequent parts\n if (insertCount > 0) {\n while (partIndex !== -1) {\n parts[partIndex].index += insertCount;\n partIndex = nextActiveIndexInTemplateParts(parts, partIndex);\n }\n return;\n }\n partIndex = nextActiveIndexInTemplateParts(parts, partIndex);\n }\n }\n}\n//# sourceMappingURL=modify-template.js.map\n\n//# sourceURL=webpack:///./node_modules/lit-element/node_modules/lit-html/lib/modify-template.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/lit-element/node_modules/lit-html/lib/part.js":
|
|
/*!********************************************************************!*\
|
|
!*** ./node_modules/lit-element/node_modules/lit-html/lib/part.js ***!
|
|
\********************************************************************/
|
|
/*! exports provided: noChange, nothing */
|
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"noChange\", function() { return noChange; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"nothing\", function() { return nothing; });\n/**\n * @license\n * Copyright (c) 2018 The Polymer Project Authors. All rights reserved.\n * This code may only be used under the BSD style license found at\n * http://polymer.github.io/LICENSE.txt\n * The complete set of authors may be found at\n * http://polymer.github.io/AUTHORS.txt\n * The complete set of contributors may be found at\n * http://polymer.github.io/CONTRIBUTORS.txt\n * Code distributed by Google as part of the polymer project is also\n * subject to an additional IP rights grant found at\n * http://polymer.github.io/PATENTS.txt\n */\n/**\n * A sentinel value that signals that a value was handled by a directive and\n * should not be written to the DOM.\n */\nconst noChange = {};\n/**\n * A sentinel value that signals a NodePart to fully clear its content.\n */\nconst nothing = {};\n//# sourceMappingURL=part.js.map\n\n//# sourceURL=webpack:///./node_modules/lit-element/node_modules/lit-html/lib/part.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/lit-element/node_modules/lit-html/lib/parts.js":
|
|
/*!*********************************************************************!*\
|
|
!*** ./node_modules/lit-element/node_modules/lit-html/lib/parts.js ***!
|
|
\*********************************************************************/
|
|
/*! exports provided: isPrimitive, isIterable, AttributeCommitter, AttributePart, NodePart, BooleanAttributePart, PropertyCommitter, PropertyPart, EventPart */
|
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"isPrimitive\", function() { return isPrimitive; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"isIterable\", function() { return isIterable; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"AttributeCommitter\", function() { return AttributeCommitter; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"AttributePart\", function() { return AttributePart; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"NodePart\", function() { return NodePart; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"BooleanAttributePart\", function() { return BooleanAttributePart; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"PropertyCommitter\", function() { return PropertyCommitter; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"PropertyPart\", function() { return PropertyPart; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"EventPart\", function() { return EventPart; });\n/* harmony import */ var _directive_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./directive.js */ \"./node_modules/lit-element/node_modules/lit-html/lib/directive.js\");\n/* harmony import */ var _dom_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./dom.js */ \"./node_modules/lit-element/node_modules/lit-html/lib/dom.js\");\n/* harmony import */ var _part_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./part.js */ \"./node_modules/lit-element/node_modules/lit-html/lib/part.js\");\n/* harmony import */ var _template_instance_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./template-instance.js */ \"./node_modules/lit-element/node_modules/lit-html/lib/template-instance.js\");\n/* harmony import */ var _template_result_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./template-result.js */ \"./node_modules/lit-element/node_modules/lit-html/lib/template-result.js\");\n/* harmony import */ var _template_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./template.js */ \"./node_modules/lit-element/node_modules/lit-html/lib/template.js\");\n/**\n * @license\n * Copyright (c) 2017 The Polymer Project Authors. All rights reserved.\n * This code may only be used under the BSD style license found at\n * http://polymer.github.io/LICENSE.txt\n * The complete set of authors may be found at\n * http://polymer.github.io/AUTHORS.txt\n * The complete set of contributors may be found at\n * http://polymer.github.io/CONTRIBUTORS.txt\n * Code distributed by Google as part of the polymer project is also\n * subject to an additional IP rights grant found at\n * http://polymer.github.io/PATENTS.txt\n */\n/**\n * @module lit-html\n */\n\n\n\n\n\n\nconst isPrimitive = (value) => {\n return (value === null ||\n !(typeof value === 'object' || typeof value === 'function'));\n};\nconst isIterable = (value) => {\n return Array.isArray(value) ||\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n !!(value && value[Symbol.iterator]);\n};\n/**\n * Writes attribute values to the DOM for a group of AttributeParts bound to a\n * single attribute. The value is only set once even if there are multiple parts\n * for an attribute.\n */\nclass AttributeCommitter {\n constructor(element, name, strings) {\n this.dirty = true;\n this.element = element;\n this.name = name;\n this.strings = strings;\n this.parts = [];\n for (let i = 0; i < strings.length - 1; i++) {\n this.parts[i] = this._createPart();\n }\n }\n /**\n * Creates a single part. Override this to create a differnt type of part.\n */\n _createPart() {\n return new AttributePart(this);\n }\n _getValue() {\n const strings = this.strings;\n const l = strings.length - 1;\n let text = '';\n for (let i = 0; i < l; i++) {\n text += strings[i];\n const part = this.parts[i];\n if (part !== undefined) {\n const v = part.value;\n if (isPrimitive(v) || !isIterable(v)) {\n text += typeof v === 'string' ? v : String(v);\n }\n else {\n for (const t of v) {\n text += typeof t === 'string' ? t : String(t);\n }\n }\n }\n }\n text += strings[l];\n return text;\n }\n commit() {\n if (this.dirty) {\n this.dirty = false;\n this.element.setAttribute(this.name, this._getValue());\n }\n }\n}\n/**\n * A Part that controls all or part of an attribute value.\n */\nclass AttributePart {\n constructor(committer) {\n this.value = undefined;\n this.committer = committer;\n }\n setValue(value) {\n if (value !== _part_js__WEBPACK_IMPORTED_MODULE_2__[\"noChange\"] && (!isPrimitive(value) || value !== this.value)) {\n this.value = value;\n // If the value is a not a directive, dirty the committer so that it'll\n // call setAttribute. If the value is a directive, it'll dirty the\n // committer if it calls setValue().\n if (!Object(_directive_js__WEBPACK_IMPORTED_MODULE_0__[\"isDirective\"])(value)) {\n this.committer.dirty = true;\n }\n }\n }\n commit() {\n while (Object(_directive_js__WEBPACK_IMPORTED_MODULE_0__[\"isDirective\"])(this.value)) {\n const directive = this.value;\n this.value = _part_js__WEBPACK_IMPORTED_MODULE_2__[\"noChange\"];\n directive(this);\n }\n if (this.value === _part_js__WEBPACK_IMPORTED_MODULE_2__[\"noChange\"]) {\n return;\n }\n this.committer.commit();\n }\n}\n/**\n * A Part that controls a location within a Node tree. Like a Range, NodePart\n * has start and end locations and can set and update the Nodes between those\n * locations.\n *\n * NodeParts support several value types: primitives, Nodes, TemplateResults,\n * as well as arrays and iterables of those types.\n */\nclass NodePart {\n constructor(options) {\n this.value = undefined;\n this.__pendingValue = undefined;\n this.options = options;\n }\n /**\n * Appends this part into a container.\n *\n * This part must be empty, as its contents are not automatically moved.\n */\n appendInto(container) {\n this.startNode = container.appendChild(Object(_template_js__WEBPACK_IMPORTED_MODULE_5__[\"createMarker\"])());\n this.endNode = container.appendChild(Object(_template_js__WEBPACK_IMPORTED_MODULE_5__[\"createMarker\"])());\n }\n /**\n * Inserts this part after the `ref` node (between `ref` and `ref`'s next\n * sibling). Both `ref` and its next sibling must be static, unchanging nodes\n * such as those that appear in a literal section of a template.\n *\n * This part must be empty, as its contents are not automatically moved.\n */\n insertAfterNode(ref) {\n this.startNode = ref;\n this.endNode = ref.nextSibling;\n }\n /**\n * Appends this part into a parent part.\n *\n * This part must be empty, as its contents are not automatically moved.\n */\n appendIntoPart(part) {\n part.__insert(this.startNode = Object(_template_js__WEBPACK_IMPORTED_MODULE_5__[\"createMarker\"])());\n part.__insert(this.endNode = Object(_template_js__WEBPACK_IMPORTED_MODULE_5__[\"createMarker\"])());\n }\n /**\n * Inserts this part after the `ref` part.\n *\n * This part must be empty, as its contents are not automatically moved.\n */\n insertAfterPart(ref) {\n ref.__insert(this.startNode = Object(_template_js__WEBPACK_IMPORTED_MODULE_5__[\"createMarker\"])());\n this.endNode = ref.endNode;\n ref.endNode = this.startNode;\n }\n setValue(value) {\n this.__pendingValue = value;\n }\n commit() {\n if (this.startNode.parentNode === null) {\n return;\n }\n while (Object(_directive_js__WEBPACK_IMPORTED_MODULE_0__[\"isDirective\"])(this.__pendingValue)) {\n const directive = this.__pendingValue;\n this.__pendingValue = _part_js__WEBPACK_IMPORTED_MODULE_2__[\"noChange\"];\n directive(this);\n }\n const value = this.__pendingValue;\n if (value === _part_js__WEBPACK_IMPORTED_MODULE_2__[\"noChange\"]) {\n return;\n }\n if (isPrimitive(value)) {\n if (value !== this.value) {\n this.__commitText(value);\n }\n }\n else if (value instanceof _template_result_js__WEBPACK_IMPORTED_MODULE_4__[\"TemplateResult\"]) {\n this.__commitTemplateResult(value);\n }\n else if (value instanceof Node) {\n this.__commitNode(value);\n }\n else if (isIterable(value)) {\n this.__commitIterable(value);\n }\n else if (value === _part_js__WEBPACK_IMPORTED_MODULE_2__[\"nothing\"]) {\n this.value = _part_js__WEBPACK_IMPORTED_MODULE_2__[\"nothing\"];\n this.clear();\n }\n else {\n // Fallback, will render the string representation\n this.__commitText(value);\n }\n }\n __insert(node) {\n this.endNode.parentNode.insertBefore(node, this.endNode);\n }\n __commitNode(value) {\n if (this.value === value) {\n return;\n }\n this.clear();\n this.__insert(value);\n this.value = value;\n }\n __commitText(value) {\n const node = this.startNode.nextSibling;\n value = value == null ? '' : value;\n // If `value` isn't already a string, we explicitly convert it here in case\n // it can't be implicitly converted - i.e. it's a symbol.\n const valueAsString = typeof value === 'string' ? value : String(value);\n if (node === this.endNode.previousSibling &&\n node.nodeType === 3 /* Node.TEXT_NODE */) {\n // If we only have a single text node between the markers, we can just\n // set its value, rather than replacing it.\n // TODO(justinfagnani): Can we just check if this.value is primitive?\n node.data = valueAsString;\n }\n else {\n this.__commitNode(document.createTextNode(valueAsString));\n }\n this.value = value;\n }\n __commitTemplateResult(value) {\n const template = this.options.templateFactory(value);\n if (this.value instanceof _template_instance_js__WEBPACK_IMPORTED_MODULE_3__[\"TemplateInstance\"] &&\n this.value.template === template) {\n this.value.update(value.values);\n }\n else {\n // Make sure we propagate the template processor from the TemplateResult\n // so that we use its syntax extension, etc. The template factory comes\n // from the render function options so that it can control template\n // caching and preprocessing.\n const instance = new _template_instance_js__WEBPACK_IMPORTED_MODULE_3__[\"TemplateInstance\"](template, value.processor, this.options);\n const fragment = instance._clone();\n instance.update(value.values);\n this.__commitNode(fragment);\n this.value = instance;\n }\n }\n __commitIterable(value) {\n // For an Iterable, we create a new InstancePart per item, then set its\n // value to the item. This is a little bit of overhead for every item in\n // an Iterable, but it lets us recurse easily and efficiently update Arrays\n // of TemplateResults that will be commonly returned from expressions like:\n // array.map((i) => html`${i}`), by reusing existing TemplateInstances.\n // If _value is an array, then the previous render was of an\n // iterable and _value will contain the NodeParts from the previous\n // render. If _value is not an array, clear this part and make a new\n // array for NodeParts.\n if (!Array.isArray(this.value)) {\n this.value = [];\n this.clear();\n }\n // Lets us keep track of how many items we stamped so we can clear leftover\n // items from a previous render\n const itemParts = this.value;\n let partIndex = 0;\n let itemPart;\n for (const item of value) {\n // Try to reuse an existing part\n itemPart = itemParts[partIndex];\n // If no existing part, create a new one\n if (itemPart === undefined) {\n itemPart = new NodePart(this.options);\n itemParts.push(itemPart);\n if (partIndex === 0) {\n itemPart.appendIntoPart(this);\n }\n else {\n itemPart.insertAfterPart(itemParts[partIndex - 1]);\n }\n }\n itemPart.setValue(item);\n itemPart.commit();\n partIndex++;\n }\n if (partIndex < itemParts.length) {\n // Truncate the parts array so _value reflects the current state\n itemParts.length = partIndex;\n this.clear(itemPart && itemPart.endNode);\n }\n }\n clear(startNode = this.startNode) {\n Object(_dom_js__WEBPACK_IMPORTED_MODULE_1__[\"removeNodes\"])(this.startNode.parentNode, startNode.nextSibling, this.endNode);\n }\n}\n/**\n * Implements a boolean attribute, roughly as defined in the HTML\n * specification.\n *\n * If the value is truthy, then the attribute is present with a value of\n * ''. If the value is falsey, the attribute is removed.\n */\nclass BooleanAttributePart {\n constructor(element, name, strings) {\n this.value = undefined;\n this.__pendingValue = undefined;\n if (strings.length !== 2 || strings[0] !== '' || strings[1] !== '') {\n throw new Error('Boolean attributes can only contain a single expression');\n }\n this.element = element;\n this.name = name;\n this.strings = strings;\n }\n setValue(value) {\n this.__pendingValue = value;\n }\n commit() {\n while (Object(_directive_js__WEBPACK_IMPORTED_MODULE_0__[\"isDirective\"])(this.__pendingValue)) {\n const directive = this.__pendingValue;\n this.__pendingValue = _part_js__WEBPACK_IMPORTED_MODULE_2__[\"noChange\"];\n directive(this);\n }\n if (this.__pendingValue === _part_js__WEBPACK_IMPORTED_MODULE_2__[\"noChange\"]) {\n return;\n }\n const value = !!this.__pendingValue;\n if (this.value !== value) {\n if (value) {\n this.element.setAttribute(this.name, '');\n }\n else {\n this.element.removeAttribute(this.name);\n }\n this.value = value;\n }\n this.__pendingValue = _part_js__WEBPACK_IMPORTED_MODULE_2__[\"noChange\"];\n }\n}\n/**\n * Sets attribute values for PropertyParts, so that the value is only set once\n * even if there are multiple parts for a property.\n *\n * If an expression controls the whole property value, then the value is simply\n * assigned to the property under control. If there are string literals or\n * multiple expressions, then the strings are expressions are interpolated into\n * a string first.\n */\nclass PropertyCommitter extends AttributeCommitter {\n constructor(element, name, strings) {\n super(element, name, strings);\n this.single =\n (strings.length === 2 && strings[0] === '' && strings[1] === '');\n }\n _createPart() {\n return new PropertyPart(this);\n }\n _getValue() {\n if (this.single) {\n return this.parts[0].value;\n }\n return super._getValue();\n }\n commit() {\n if (this.dirty) {\n this.dirty = false;\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n this.element[this.name] = this._getValue();\n }\n }\n}\nclass PropertyPart extends AttributePart {\n}\n// Detect event listener options support. If the `capture` property is read\n// from the options object, then options are supported. If not, then the third\n// argument to add/removeEventListener is interpreted as the boolean capture\n// value so we should only pass the `capture` property.\nlet eventOptionsSupported = false;\n// Wrap into an IIFE because MS Edge <= v41 does not support having try/catch\n// blocks right into the body of a module\n(() => {\n try {\n const options = {\n get capture() {\n eventOptionsSupported = true;\n return false;\n }\n };\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n window.addEventListener('test', options, options);\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n window.removeEventListener('test', options, options);\n }\n catch (_e) {\n // event options not supported\n }\n})();\nclass EventPart {\n constructor(element, eventName, eventContext) {\n this.value = undefined;\n this.__pendingValue = undefined;\n this.element = element;\n this.eventName = eventName;\n this.eventContext = eventContext;\n this.__boundHandleEvent = (e) => this.handleEvent(e);\n }\n setValue(value) {\n this.__pendingValue = value;\n }\n commit() {\n while (Object(_directive_js__WEBPACK_IMPORTED_MODULE_0__[\"isDirective\"])(this.__pendingValue)) {\n const directive = this.__pendingValue;\n this.__pendingValue = _part_js__WEBPACK_IMPORTED_MODULE_2__[\"noChange\"];\n directive(this);\n }\n if (this.__pendingValue === _part_js__WEBPACK_IMPORTED_MODULE_2__[\"noChange\"]) {\n return;\n }\n const newListener = this.__pendingValue;\n const oldListener = this.value;\n const shouldRemoveListener = newListener == null ||\n oldListener != null &&\n (newListener.capture !== oldListener.capture ||\n newListener.once !== oldListener.once ||\n newListener.passive !== oldListener.passive);\n const shouldAddListener = newListener != null && (oldListener == null || shouldRemoveListener);\n if (shouldRemoveListener) {\n this.element.removeEventListener(this.eventName, this.__boundHandleEvent, this.__options);\n }\n if (shouldAddListener) {\n this.__options = getOptions(newListener);\n this.element.addEventListener(this.eventName, this.__boundHandleEvent, this.__options);\n }\n this.value = newListener;\n this.__pendingValue = _part_js__WEBPACK_IMPORTED_MODULE_2__[\"noChange\"];\n }\n handleEvent(event) {\n if (typeof this.value === 'function') {\n this.value.call(this.eventContext || this.element, event);\n }\n else {\n this.value.handleEvent(event);\n }\n }\n}\n// We copy options because of the inconsistent behavior of browsers when reading\n// the third argument of add/removeEventListener. IE11 doesn't support options\n// at all. Chrome 41 only reads `capture` if the argument is an object.\nconst getOptions = (o) => o &&\n (eventOptionsSupported ?\n { capture: o.capture, passive: o.passive, once: o.once } :\n o.capture);\n//# sourceMappingURL=parts.js.map\n\n//# sourceURL=webpack:///./node_modules/lit-element/node_modules/lit-html/lib/parts.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/lit-element/node_modules/lit-html/lib/render.js":
|
|
/*!**********************************************************************!*\
|
|
!*** ./node_modules/lit-element/node_modules/lit-html/lib/render.js ***!
|
|
\**********************************************************************/
|
|
/*! exports provided: parts, render */
|
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"parts\", function() { return parts; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"render\", function() { return render; });\n/* harmony import */ var _dom_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./dom.js */ \"./node_modules/lit-element/node_modules/lit-html/lib/dom.js\");\n/* harmony import */ var _parts_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./parts.js */ \"./node_modules/lit-element/node_modules/lit-html/lib/parts.js\");\n/* harmony import */ var _template_factory_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./template-factory.js */ \"./node_modules/lit-element/node_modules/lit-html/lib/template-factory.js\");\n/**\n * @license\n * Copyright (c) 2017 The Polymer Project Authors. All rights reserved.\n * This code may only be used under the BSD style license found at\n * http://polymer.github.io/LICENSE.txt\n * The complete set of authors may be found at\n * http://polymer.github.io/AUTHORS.txt\n * The complete set of contributors may be found at\n * http://polymer.github.io/CONTRIBUTORS.txt\n * Code distributed by Google as part of the polymer project is also\n * subject to an additional IP rights grant found at\n * http://polymer.github.io/PATENTS.txt\n */\n/**\n * @module lit-html\n */\n\n\n\nconst parts = new WeakMap();\n/**\n * Renders a template result or other value to a container.\n *\n * To update a container with new values, reevaluate the template literal and\n * call `render` with the new result.\n *\n * @param result Any value renderable by NodePart - typically a TemplateResult\n * created by evaluating a template tag like `html` or `svg`.\n * @param container A DOM parent to render to. The entire contents are either\n * replaced, or efficiently updated if the same result type was previous\n * rendered there.\n * @param options RenderOptions for the entire render tree rendered to this\n * container. Render options must *not* change between renders to the same\n * container, as those changes will not effect previously rendered DOM.\n */\nconst render = (result, container, options) => {\n let part = parts.get(container);\n if (part === undefined) {\n Object(_dom_js__WEBPACK_IMPORTED_MODULE_0__[\"removeNodes\"])(container, container.firstChild);\n parts.set(container, part = new _parts_js__WEBPACK_IMPORTED_MODULE_1__[\"NodePart\"](Object.assign({ templateFactory: _template_factory_js__WEBPACK_IMPORTED_MODULE_2__[\"templateFactory\"] }, options)));\n part.appendInto(container);\n }\n part.setValue(result);\n part.commit();\n};\n//# sourceMappingURL=render.js.map\n\n//# sourceURL=webpack:///./node_modules/lit-element/node_modules/lit-html/lib/render.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/lit-element/node_modules/lit-html/lib/shady-render.js":
|
|
/*!****************************************************************************!*\
|
|
!*** ./node_modules/lit-element/node_modules/lit-html/lib/shady-render.js ***!
|
|
\****************************************************************************/
|
|
/*! exports provided: html, svg, TemplateResult, render */
|
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"render\", function() { return render; });\n/* harmony import */ var _dom_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./dom.js */ \"./node_modules/lit-element/node_modules/lit-html/lib/dom.js\");\n/* harmony import */ var _modify_template_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./modify-template.js */ \"./node_modules/lit-element/node_modules/lit-html/lib/modify-template.js\");\n/* harmony import */ var _render_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./render.js */ \"./node_modules/lit-element/node_modules/lit-html/lib/render.js\");\n/* harmony import */ var _template_factory_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./template-factory.js */ \"./node_modules/lit-element/node_modules/lit-html/lib/template-factory.js\");\n/* harmony import */ var _template_instance_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./template-instance.js */ \"./node_modules/lit-element/node_modules/lit-html/lib/template-instance.js\");\n/* harmony import */ var _template_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./template.js */ \"./node_modules/lit-element/node_modules/lit-html/lib/template.js\");\n/* harmony import */ var _lit_html_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../lit-html.js */ \"./node_modules/lit-element/node_modules/lit-html/lit-html.js\");\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"html\", function() { return _lit_html_js__WEBPACK_IMPORTED_MODULE_6__[\"html\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"svg\", function() { return _lit_html_js__WEBPACK_IMPORTED_MODULE_6__[\"svg\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"TemplateResult\", function() { return _lit_html_js__WEBPACK_IMPORTED_MODULE_6__[\"TemplateResult\"]; });\n\n/**\n * @license\n * Copyright (c) 2017 The Polymer Project Authors. All rights reserved.\n * This code may only be used under the BSD style license found at\n * http://polymer.github.io/LICENSE.txt\n * The complete set of authors may be found at\n * http://polymer.github.io/AUTHORS.txt\n * The complete set of contributors may be found at\n * http://polymer.github.io/CONTRIBUTORS.txt\n * Code distributed by Google as part of the polymer project is also\n * subject to an additional IP rights grant found at\n * http://polymer.github.io/PATENTS.txt\n */\n/**\n * Module to add shady DOM/shady CSS polyfill support to lit-html template\n * rendering. See the [[render]] method for details.\n *\n * @module shady-render\n * @preferred\n */\n/**\n * Do not remove this comment; it keeps typedoc from misplacing the module\n * docs.\n */\n\n\n\n\n\n\n\n// Get a key to lookup in `templateCaches`.\nconst getTemplateCacheKey = (type, scopeName) => `${type}--${scopeName}`;\nlet compatibleShadyCSSVersion = true;\nif (typeof window.ShadyCSS === 'undefined') {\n compatibleShadyCSSVersion = false;\n}\nelse if (typeof window.ShadyCSS.prepareTemplateDom === 'undefined') {\n console.warn(`Incompatible ShadyCSS version detected. ` +\n `Please update to at least @webcomponents/webcomponentsjs@2.0.2 and ` +\n `@webcomponents/shadycss@1.3.1.`);\n compatibleShadyCSSVersion = false;\n}\n/**\n * Template factory which scopes template DOM using ShadyCSS.\n * @param scopeName {string}\n */\nconst shadyTemplateFactory = (scopeName) => (result) => {\n const cacheKey = getTemplateCacheKey(result.type, scopeName);\n let templateCache = _template_factory_js__WEBPACK_IMPORTED_MODULE_3__[\"templateCaches\"].get(cacheKey);\n if (templateCache === undefined) {\n templateCache = {\n stringsArray: new WeakMap(),\n keyString: new Map()\n };\n _template_factory_js__WEBPACK_IMPORTED_MODULE_3__[\"templateCaches\"].set(cacheKey, templateCache);\n }\n let template = templateCache.stringsArray.get(result.strings);\n if (template !== undefined) {\n return template;\n }\n const key = result.strings.join(_template_js__WEBPACK_IMPORTED_MODULE_5__[\"marker\"]);\n template = templateCache.keyString.get(key);\n if (template === undefined) {\n const element = result.getTemplateElement();\n if (compatibleShadyCSSVersion) {\n window.ShadyCSS.prepareTemplateDom(element, scopeName);\n }\n template = new _template_js__WEBPACK_IMPORTED_MODULE_5__[\"Template\"](result, element);\n templateCache.keyString.set(key, template);\n }\n templateCache.stringsArray.set(result.strings, template);\n return template;\n};\nconst TEMPLATE_TYPES = ['html', 'svg'];\n/**\n * Removes all style elements from Templates for the given scopeName.\n */\nconst removeStylesFromLitTemplates = (scopeName) => {\n TEMPLATE_TYPES.forEach((type) => {\n const templates = _template_factory_js__WEBPACK_IMPORTED_MODULE_3__[\"templateCaches\"].get(getTemplateCacheKey(type, scopeName));\n if (templates !== undefined) {\n templates.keyString.forEach((template) => {\n const { element: { content } } = template;\n // IE 11 doesn't support the iterable param Set constructor\n const styles = new Set();\n Array.from(content.querySelectorAll('style')).forEach((s) => {\n styles.add(s);\n });\n Object(_modify_template_js__WEBPACK_IMPORTED_MODULE_1__[\"removeNodesFromTemplate\"])(template, styles);\n });\n }\n });\n};\nconst shadyRenderSet = new Set();\n/**\n * For the given scope name, ensures that ShadyCSS style scoping is performed.\n * This is done just once per scope name so the fragment and template cannot\n * be modified.\n * (1) extracts styles from the rendered fragment and hands them to ShadyCSS\n * to be scoped and appended to the document\n * (2) removes style elements from all lit-html Templates for this scope name.\n *\n * Note, <style> elements can only be placed into templates for the\n * initial rendering of the scope. If <style> elements are included in templates\n * dynamically rendered to the scope (after the first scope render), they will\n * not be scoped and the <style> will be left in the template and rendered\n * output.\n */\nconst prepareTemplateStyles = (scopeName, renderedDOM, template) => {\n shadyRenderSet.add(scopeName);\n // If `renderedDOM` is stamped from a Template, then we need to edit that\n // Template's underlying template element. Otherwise, we create one here\n // to give to ShadyCSS, which still requires one while scoping.\n const templateElement = !!template ? template.element : document.createElement('template');\n // Move styles out of rendered DOM and store.\n const styles = renderedDOM.querySelectorAll('style');\n const { length } = styles;\n // If there are no styles, skip unnecessary work\n if (length === 0) {\n // Ensure prepareTemplateStyles is called to support adding\n // styles via `prepareAdoptedCssText` since that requires that\n // `prepareTemplateStyles` is called.\n //\n // ShadyCSS will only update styles containing @apply in the template\n // given to `prepareTemplateStyles`. If no lit Template was given,\n // ShadyCSS will not be able to update uses of @apply in any relevant\n // template. However, this is not a problem because we only create the\n // template for the purpose of supporting `prepareAdoptedCssText`,\n // which doesn't support @apply at all.\n window.ShadyCSS.prepareTemplateStyles(templateElement, scopeName);\n return;\n }\n const condensedStyle = document.createElement('style');\n // Collect styles into a single style. This helps us make sure ShadyCSS\n // manipulations will not prevent us from being able to fix up template\n // part indices.\n // NOTE: collecting styles is inefficient for browsers but ShadyCSS\n // currently does this anyway. When it does not, this should be changed.\n for (let i = 0; i < length; i++) {\n const style = styles[i];\n style.parentNode.removeChild(style);\n condensedStyle.textContent += style.textContent;\n }\n // Remove styles from nested templates in this scope.\n removeStylesFromLitTemplates(scopeName);\n // And then put the condensed style into the \"root\" template passed in as\n // `template`.\n const content = templateElement.content;\n if (!!template) {\n Object(_modify_template_js__WEBPACK_IMPORTED_MODULE_1__[\"insertNodeIntoTemplate\"])(template, condensedStyle, content.firstChild);\n }\n else {\n content.insertBefore(condensedStyle, content.firstChild);\n }\n // Note, it's important that ShadyCSS gets the template that `lit-html`\n // will actually render so that it can update the style inside when\n // needed (e.g. @apply native Shadow DOM case).\n window.ShadyCSS.prepareTemplateStyles(templateElement, scopeName);\n const style = content.querySelector('style');\n if (window.ShadyCSS.nativeShadow && style !== null) {\n // When in native Shadow DOM, ensure the style created by ShadyCSS is\n // included in initially rendered output (`renderedDOM`).\n renderedDOM.insertBefore(style.cloneNode(true), renderedDOM.firstChild);\n }\n else if (!!template) {\n // When no style is left in the template, parts will be broken as a\n // result. To fix this, we put back the style node ShadyCSS removed\n // and then tell lit to remove that node from the template.\n // There can be no style in the template in 2 cases (1) when Shady DOM\n // is in use, ShadyCSS removes all styles, (2) when native Shadow DOM\n // is in use ShadyCSS removes the style if it contains no content.\n // NOTE, ShadyCSS creates its own style so we can safely add/remove\n // `condensedStyle` here.\n content.insertBefore(condensedStyle, content.firstChild);\n const removes = new Set();\n removes.add(condensedStyle);\n Object(_modify_template_js__WEBPACK_IMPORTED_MODULE_1__[\"removeNodesFromTemplate\"])(template, removes);\n }\n};\n/**\n * Extension to the standard `render` method which supports rendering\n * to ShadowRoots when the ShadyDOM (https://github.com/webcomponents/shadydom)\n * and ShadyCSS (https://github.com/webcomponents/shadycss) polyfills are used\n * or when the webcomponentsjs\n * (https://github.com/webcomponents/webcomponentsjs) polyfill is used.\n *\n * Adds a `scopeName` option which is used to scope element DOM and stylesheets\n * when native ShadowDOM is unavailable. The `scopeName` will be added to\n * the class attribute of all rendered DOM. In addition, any style elements will\n * be automatically re-written with this `scopeName` selector and moved out\n * of the rendered DOM and into the document `<head>`.\n *\n * It is common to use this render method in conjunction with a custom element\n * which renders a shadowRoot. When this is done, typically the element's\n * `localName` should be used as the `scopeName`.\n *\n * In addition to DOM scoping, ShadyCSS also supports a basic shim for css\n * custom properties (needed only on older browsers like IE11) and a shim for\n * a deprecated feature called `@apply` that supports applying a set of css\n * custom properties to a given location.\n *\n * Usage considerations:\n *\n * * Part values in `<style>` elements are only applied the first time a given\n * `scopeName` renders. Subsequent changes to parts in style elements will have\n * no effect. Because of this, parts in style elements should only be used for\n * values that will never change, for example parts that set scope-wide theme\n * values or parts which render shared style elements.\n *\n * * Note, due to a limitation of the ShadyDOM polyfill, rendering in a\n * custom element's `constructor` is not supported. Instead rendering should\n * either done asynchronously, for example at microtask timing (for example\n * `Promise.resolve()`), or be deferred until the first time the element's\n * `connectedCallback` runs.\n *\n * Usage considerations when using shimmed custom properties or `@apply`:\n *\n * * Whenever any dynamic changes are made which affect\n * css custom properties, `ShadyCSS.styleElement(element)` must be called\n * to update the element. There are two cases when this is needed:\n * (1) the element is connected to a new parent, (2) a class is added to the\n * element that causes it to match different custom properties.\n * To address the first case when rendering a custom element, `styleElement`\n * should be called in the element's `connectedCallback`.\n *\n * * Shimmed custom properties may only be defined either for an entire\n * shadowRoot (for example, in a `:host` rule) or via a rule that directly\n * matches an element with a shadowRoot. In other words, instead of flowing from\n * parent to child as do native css custom properties, shimmed custom properties\n * flow only from shadowRoots to nested shadowRoots.\n *\n * * When using `@apply` mixing css shorthand property names with\n * non-shorthand names (for example `border` and `border-width`) is not\n * supported.\n */\nconst render = (result, container, options) => {\n if (!options || typeof options !== 'object' || !options.scopeName) {\n throw new Error('The `scopeName` option is required.');\n }\n const scopeName = options.scopeName;\n const hasRendered = _render_js__WEBPACK_IMPORTED_MODULE_2__[\"parts\"].has(container);\n const needsScoping = compatibleShadyCSSVersion &&\n container.nodeType === 11 /* Node.DOCUMENT_FRAGMENT_NODE */ &&\n !!container.host;\n // Handle first render to a scope specially...\n const firstScopeRender = needsScoping && !shadyRenderSet.has(scopeName);\n // On first scope render, render into a fragment; this cannot be a single\n // fragment that is reused since nested renders can occur synchronously.\n const renderContainer = firstScopeRender ? document.createDocumentFragment() : container;\n Object(_render_js__WEBPACK_IMPORTED_MODULE_2__[\"render\"])(result, renderContainer, Object.assign({ templateFactory: shadyTemplateFactory(scopeName) }, options));\n // When performing first scope render,\n // (1) We've rendered into a fragment so that there's a chance to\n // `prepareTemplateStyles` before sub-elements hit the DOM\n // (which might cause them to render based on a common pattern of\n // rendering in a custom element's `connectedCallback`);\n // (2) Scope the template with ShadyCSS one time only for this scope.\n // (3) Render the fragment into the container and make sure the\n // container knows its `part` is the one we just rendered. This ensures\n // DOM will be re-used on subsequent renders.\n if (firstScopeRender) {\n const part = _render_js__WEBPACK_IMPORTED_MODULE_2__[\"parts\"].get(renderContainer);\n _render_js__WEBPACK_IMPORTED_MODULE_2__[\"parts\"].delete(renderContainer);\n // ShadyCSS might have style sheets (e.g. from `prepareAdoptedCssText`)\n // that should apply to `renderContainer` even if the rendered value is\n // not a TemplateInstance. However, it will only insert scoped styles\n // into the document if `prepareTemplateStyles` has already been called\n // for the given scope name.\n const template = part.value instanceof _template_instance_js__WEBPACK_IMPORTED_MODULE_4__[\"TemplateInstance\"] ?\n part.value.template :\n undefined;\n prepareTemplateStyles(scopeName, renderContainer, template);\n Object(_dom_js__WEBPACK_IMPORTED_MODULE_0__[\"removeNodes\"])(container, container.firstChild);\n container.appendChild(renderContainer);\n _render_js__WEBPACK_IMPORTED_MODULE_2__[\"parts\"].set(container, part);\n }\n // After elements have hit the DOM, update styling if this is the\n // initial render to this container.\n // This is needed whenever dynamic changes are made so it would be\n // safest to do every render; however, this would regress performance\n // so we leave it up to the user to call `ShadyCSS.styleElement`\n // for dynamic changes.\n if (!hasRendered && needsScoping) {\n window.ShadyCSS.styleElement(container.host);\n }\n};\n//# sourceMappingURL=shady-render.js.map\n\n//# sourceURL=webpack:///./node_modules/lit-element/node_modules/lit-html/lib/shady-render.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/lit-element/node_modules/lit-html/lib/template-factory.js":
|
|
/*!********************************************************************************!*\
|
|
!*** ./node_modules/lit-element/node_modules/lit-html/lib/template-factory.js ***!
|
|
\********************************************************************************/
|
|
/*! exports provided: templateFactory, templateCaches */
|
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"templateFactory\", function() { return templateFactory; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"templateCaches\", function() { return templateCaches; });\n/* harmony import */ var _template_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./template.js */ \"./node_modules/lit-element/node_modules/lit-html/lib/template.js\");\n/**\n * @license\n * Copyright (c) 2017 The Polymer Project Authors. All rights reserved.\n * This code may only be used under the BSD style license found at\n * http://polymer.github.io/LICENSE.txt\n * The complete set of authors may be found at\n * http://polymer.github.io/AUTHORS.txt\n * The complete set of contributors may be found at\n * http://polymer.github.io/CONTRIBUTORS.txt\n * Code distributed by Google as part of the polymer project is also\n * subject to an additional IP rights grant found at\n * http://polymer.github.io/PATENTS.txt\n */\n\n/**\n * The default TemplateFactory which caches Templates keyed on\n * result.type and result.strings.\n */\nfunction templateFactory(result) {\n let templateCache = templateCaches.get(result.type);\n if (templateCache === undefined) {\n templateCache = {\n stringsArray: new WeakMap(),\n keyString: new Map()\n };\n templateCaches.set(result.type, templateCache);\n }\n let template = templateCache.stringsArray.get(result.strings);\n if (template !== undefined) {\n return template;\n }\n // If the TemplateStringsArray is new, generate a key from the strings\n // This key is shared between all templates with identical content\n const key = result.strings.join(_template_js__WEBPACK_IMPORTED_MODULE_0__[\"marker\"]);\n // Check if we already have a Template for this key\n template = templateCache.keyString.get(key);\n if (template === undefined) {\n // If we have not seen this key before, create a new Template\n template = new _template_js__WEBPACK_IMPORTED_MODULE_0__[\"Template\"](result, result.getTemplateElement());\n // Cache the Template for this key\n templateCache.keyString.set(key, template);\n }\n // Cache all future queries for this TemplateStringsArray\n templateCache.stringsArray.set(result.strings, template);\n return template;\n}\nconst templateCaches = new Map();\n//# sourceMappingURL=template-factory.js.map\n\n//# sourceURL=webpack:///./node_modules/lit-element/node_modules/lit-html/lib/template-factory.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/lit-element/node_modules/lit-html/lib/template-instance.js":
|
|
/*!*********************************************************************************!*\
|
|
!*** ./node_modules/lit-element/node_modules/lit-html/lib/template-instance.js ***!
|
|
\*********************************************************************************/
|
|
/*! exports provided: TemplateInstance */
|
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"TemplateInstance\", function() { return TemplateInstance; });\n/* harmony import */ var _dom_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./dom.js */ \"./node_modules/lit-element/node_modules/lit-html/lib/dom.js\");\n/* harmony import */ var _template_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./template.js */ \"./node_modules/lit-element/node_modules/lit-html/lib/template.js\");\n/**\n * @license\n * Copyright (c) 2017 The Polymer Project Authors. All rights reserved.\n * This code may only be used under the BSD style license found at\n * http://polymer.github.io/LICENSE.txt\n * The complete set of authors may be found at\n * http://polymer.github.io/AUTHORS.txt\n * The complete set of contributors may be found at\n * http://polymer.github.io/CONTRIBUTORS.txt\n * Code distributed by Google as part of the polymer project is also\n * subject to an additional IP rights grant found at\n * http://polymer.github.io/PATENTS.txt\n */\n/**\n * @module lit-html\n */\n\n\n/**\n * An instance of a `Template` that can be attached to the DOM and updated\n * with new values.\n */\nclass TemplateInstance {\n constructor(template, processor, options) {\n this.__parts = [];\n this.template = template;\n this.processor = processor;\n this.options = options;\n }\n update(values) {\n let i = 0;\n for (const part of this.__parts) {\n if (part !== undefined) {\n part.setValue(values[i]);\n }\n i++;\n }\n for (const part of this.__parts) {\n if (part !== undefined) {\n part.commit();\n }\n }\n }\n _clone() {\n // There are a number of steps in the lifecycle of a template instance's\n // DOM fragment:\n // 1. Clone - create the instance fragment\n // 2. Adopt - adopt into the main document\n // 3. Process - find part markers and create parts\n // 4. Upgrade - upgrade custom elements\n // 5. Update - set node, attribute, property, etc., values\n // 6. Connect - connect to the document. Optional and outside of this\n // method.\n //\n // We have a few constraints on the ordering of these steps:\n // * We need to upgrade before updating, so that property values will pass\n // through any property setters.\n // * We would like to process before upgrading so that we're sure that the\n // cloned fragment is inert and not disturbed by self-modifying DOM.\n // * We want custom elements to upgrade even in disconnected fragments.\n //\n // Given these constraints, with full custom elements support we would\n // prefer the order: Clone, Process, Adopt, Upgrade, Update, Connect\n //\n // But Safari does not implement CustomElementRegistry#upgrade, so we\n // can not implement that order and still have upgrade-before-update and\n // upgrade disconnected fragments. So we instead sacrifice the\n // process-before-upgrade constraint, since in Custom Elements v1 elements\n // must not modify their light DOM in the constructor. We still have issues\n // when co-existing with CEv0 elements like Polymer 1, and with polyfills\n // that don't strictly adhere to the no-modification rule because shadow\n // DOM, which may be created in the constructor, is emulated by being placed\n // in the light DOM.\n //\n // The resulting order is on native is: Clone, Adopt, Upgrade, Process,\n // Update, Connect. document.importNode() performs Clone, Adopt, and Upgrade\n // in one step.\n //\n // The Custom Elements v1 polyfill supports upgrade(), so the order when\n // polyfilled is the more ideal: Clone, Process, Adopt, Upgrade, Update,\n // Connect.\n const fragment = _dom_js__WEBPACK_IMPORTED_MODULE_0__[\"isCEPolyfill\"] ?\n this.template.element.content.cloneNode(true) :\n document.importNode(this.template.element.content, true);\n const stack = [];\n const parts = this.template.parts;\n // Edge needs all 4 parameters present; IE11 needs 3rd parameter to be null\n const walker = document.createTreeWalker(fragment, 133 /* NodeFilter.SHOW_{ELEMENT|COMMENT|TEXT} */, null, false);\n let partIndex = 0;\n let nodeIndex = 0;\n let part;\n let node = walker.nextNode();\n // Loop through all the nodes and parts of a template\n while (partIndex < parts.length) {\n part = parts[partIndex];\n if (!Object(_template_js__WEBPACK_IMPORTED_MODULE_1__[\"isTemplatePartActive\"])(part)) {\n this.__parts.push(undefined);\n partIndex++;\n continue;\n }\n // Progress the tree walker until we find our next part's node.\n // Note that multiple parts may share the same node (attribute parts\n // on a single element), so this loop may not run at all.\n while (nodeIndex < part.index) {\n nodeIndex++;\n if (node.nodeName === 'TEMPLATE') {\n stack.push(node);\n walker.currentNode = node.content;\n }\n if ((node = walker.nextNode()) === null) {\n // We've exhausted the content inside a nested template element.\n // Because we still have parts (the outer for-loop), we know:\n // - There is a template in the stack\n // - The walker will find a nextNode outside the template\n walker.currentNode = stack.pop();\n node = walker.nextNode();\n }\n }\n // We've arrived at our part's node.\n if (part.type === 'node') {\n const part = this.processor.handleTextExpression(this.options);\n part.insertAfterNode(node.previousSibling);\n this.__parts.push(part);\n }\n else {\n this.__parts.push(...this.processor.handleAttributeExpressions(node, part.name, part.strings, this.options));\n }\n partIndex++;\n }\n if (_dom_js__WEBPACK_IMPORTED_MODULE_0__[\"isCEPolyfill\"]) {\n document.adoptNode(fragment);\n customElements.upgrade(fragment);\n }\n return fragment;\n }\n}\n//# sourceMappingURL=template-instance.js.map\n\n//# sourceURL=webpack:///./node_modules/lit-element/node_modules/lit-html/lib/template-instance.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/lit-element/node_modules/lit-html/lib/template-result.js":
|
|
/*!*******************************************************************************!*\
|
|
!*** ./node_modules/lit-element/node_modules/lit-html/lib/template-result.js ***!
|
|
\*******************************************************************************/
|
|
/*! exports provided: TemplateResult, SVGTemplateResult */
|
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"TemplateResult\", function() { return TemplateResult; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"SVGTemplateResult\", function() { return SVGTemplateResult; });\n/* harmony import */ var _dom_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./dom.js */ \"./node_modules/lit-element/node_modules/lit-html/lib/dom.js\");\n/* harmony import */ var _template_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./template.js */ \"./node_modules/lit-element/node_modules/lit-html/lib/template.js\");\n/**\n * @license\n * Copyright (c) 2017 The Polymer Project Authors. All rights reserved.\n * This code may only be used under the BSD style license found at\n * http://polymer.github.io/LICENSE.txt\n * The complete set of authors may be found at\n * http://polymer.github.io/AUTHORS.txt\n * The complete set of contributors may be found at\n * http://polymer.github.io/CONTRIBUTORS.txt\n * Code distributed by Google as part of the polymer project is also\n * subject to an additional IP rights grant found at\n * http://polymer.github.io/PATENTS.txt\n */\n/**\n * @module lit-html\n */\n\n\nconst commentMarker = ` ${_template_js__WEBPACK_IMPORTED_MODULE_1__[\"marker\"]} `;\n/**\n * The return type of `html`, which holds a Template and the values from\n * interpolated expressions.\n */\nclass TemplateResult {\n constructor(strings, values, type, processor) {\n this.strings = strings;\n this.values = values;\n this.type = type;\n this.processor = processor;\n }\n /**\n * Returns a string of HTML used to create a `<template>` element.\n */\n getHTML() {\n const l = this.strings.length - 1;\n let html = '';\n let isCommentBinding = false;\n for (let i = 0; i < l; i++) {\n const s = this.strings[i];\n // For each binding we want to determine the kind of marker to insert\n // into the template source before it's parsed by the browser's HTML\n // parser. The marker type is based on whether the expression is in an\n // attribute, text, or comment position.\n // * For node-position bindings we insert a comment with the marker\n // sentinel as its text content, like <!--{{lit-guid}}-->.\n // * For attribute bindings we insert just the marker sentinel for the\n // first binding, so that we support unquoted attribute bindings.\n // Subsequent bindings can use a comment marker because multi-binding\n // attributes must be quoted.\n // * For comment bindings we insert just the marker sentinel so we don't\n // close the comment.\n //\n // The following code scans the template source, but is *not* an HTML\n // parser. We don't need to track the tree structure of the HTML, only\n // whether a binding is inside a comment, and if not, if it appears to be\n // the first binding in an attribute.\n const commentOpen = s.lastIndexOf('<!--');\n // We're in comment position if we have a comment open with no following\n // comment close. Because <-- can appear in an attribute value there can\n // be false positives.\n isCommentBinding = (commentOpen > -1 || isCommentBinding) &&\n s.indexOf('-->', commentOpen + 1) === -1;\n // Check to see if we have an attribute-like sequence preceding the\n // expression. This can match \"name=value\" like structures in text,\n // comments, and attribute values, so there can be false-positives.\n const attributeMatch = _template_js__WEBPACK_IMPORTED_MODULE_1__[\"lastAttributeNameRegex\"].exec(s);\n if (attributeMatch === null) {\n // We're only in this branch if we don't have a attribute-like\n // preceding sequence. For comments, this guards against unusual\n // attribute values like <div foo=\"<!--${'bar'}\">. Cases like\n // <!-- foo=${'bar'}--> are handled correctly in the attribute branch\n // below.\n html += s + (isCommentBinding ? commentMarker : _template_js__WEBPACK_IMPORTED_MODULE_1__[\"nodeMarker\"]);\n }\n else {\n // For attributes we use just a marker sentinel, and also append a\n // $lit$ suffix to the name to opt-out of attribute-specific parsing\n // that IE and Edge do for style and certain SVG attributes.\n html += s.substr(0, attributeMatch.index) + attributeMatch[1] +\n attributeMatch[2] + _template_js__WEBPACK_IMPORTED_MODULE_1__[\"boundAttributeSuffix\"] + attributeMatch[3] +\n _template_js__WEBPACK_IMPORTED_MODULE_1__[\"marker\"];\n }\n }\n html += this.strings[l];\n return html;\n }\n getTemplateElement() {\n const template = document.createElement('template');\n template.innerHTML = this.getHTML();\n return template;\n }\n}\n/**\n * A TemplateResult for SVG fragments.\n *\n * This class wraps HTML in an `<svg>` tag in order to parse its contents in the\n * SVG namespace, then modifies the template to remove the `<svg>` tag so that\n * clones only container the original fragment.\n */\nclass SVGTemplateResult extends TemplateResult {\n getHTML() {\n return `<svg>${super.getHTML()}</svg>`;\n }\n getTemplateElement() {\n const template = super.getTemplateElement();\n const content = template.content;\n const svgElement = content.firstChild;\n content.removeChild(svgElement);\n Object(_dom_js__WEBPACK_IMPORTED_MODULE_0__[\"reparentNodes\"])(content, svgElement.firstChild);\n return template;\n }\n}\n//# sourceMappingURL=template-result.js.map\n\n//# sourceURL=webpack:///./node_modules/lit-element/node_modules/lit-html/lib/template-result.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/lit-element/node_modules/lit-html/lib/template.js":
|
|
/*!************************************************************************!*\
|
|
!*** ./node_modules/lit-element/node_modules/lit-html/lib/template.js ***!
|
|
\************************************************************************/
|
|
/*! exports provided: marker, nodeMarker, markerRegex, boundAttributeSuffix, Template, isTemplatePartActive, createMarker, lastAttributeNameRegex */
|
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"marker\", function() { return marker; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"nodeMarker\", function() { return nodeMarker; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"markerRegex\", function() { return markerRegex; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"boundAttributeSuffix\", function() { return boundAttributeSuffix; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"Template\", function() { return Template; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"isTemplatePartActive\", function() { return isTemplatePartActive; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"createMarker\", function() { return createMarker; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"lastAttributeNameRegex\", function() { return lastAttributeNameRegex; });\n/**\n * @license\n * Copyright (c) 2017 The Polymer Project Authors. All rights reserved.\n * This code may only be used under the BSD style license found at\n * http://polymer.github.io/LICENSE.txt\n * The complete set of authors may be found at\n * http://polymer.github.io/AUTHORS.txt\n * The complete set of contributors may be found at\n * http://polymer.github.io/CONTRIBUTORS.txt\n * Code distributed by Google as part of the polymer project is also\n * subject to an additional IP rights grant found at\n * http://polymer.github.io/PATENTS.txt\n */\n/**\n * An expression marker with embedded unique key to avoid collision with\n * possible text in templates.\n */\nconst marker = `{{lit-${String(Math.random()).slice(2)}}}`;\n/**\n * An expression marker used text-positions, multi-binding attributes, and\n * attributes with markup-like text values.\n */\nconst nodeMarker = `<!--${marker}-->`;\nconst markerRegex = new RegExp(`${marker}|${nodeMarker}`);\n/**\n * Suffix appended to all bound attribute names.\n */\nconst boundAttributeSuffix = '$lit$';\n/**\n * An updatable Template that tracks the location of dynamic parts.\n */\nclass Template {\n constructor(result, element) {\n this.parts = [];\n this.element = element;\n const nodesToRemove = [];\n const stack = [];\n // Edge needs all 4 parameters present; IE11 needs 3rd parameter to be null\n const walker = document.createTreeWalker(element.content, 133 /* NodeFilter.SHOW_{ELEMENT|COMMENT|TEXT} */, null, false);\n // Keeps track of the last index associated with a part. We try to delete\n // unnecessary nodes, but we never want to associate two different parts\n // to the same index. They must have a constant node between.\n let lastPartIndex = 0;\n let index = -1;\n let partIndex = 0;\n const { strings, values: { length } } = result;\n while (partIndex < length) {\n const node = walker.nextNode();\n if (node === null) {\n // We've exhausted the content inside a nested template element.\n // Because we still have parts (the outer for-loop), we know:\n // - There is a template in the stack\n // - The walker will find a nextNode outside the template\n walker.currentNode = stack.pop();\n continue;\n }\n index++;\n if (node.nodeType === 1 /* Node.ELEMENT_NODE */) {\n if (node.hasAttributes()) {\n const attributes = node.attributes;\n const { length } = attributes;\n // Per\n // https://developer.mozilla.org/en-US/docs/Web/API/NamedNodeMap,\n // attributes are not guaranteed to be returned in document order.\n // In particular, Edge/IE can return them out of order, so we cannot\n // assume a correspondence between part index and attribute index.\n let count = 0;\n for (let i = 0; i < length; i++) {\n if (endsWith(attributes[i].name, boundAttributeSuffix)) {\n count++;\n }\n }\n while (count-- > 0) {\n // Get the template literal section leading up to the first\n // expression in this attribute\n const stringForPart = strings[partIndex];\n // Find the attribute name\n const name = lastAttributeNameRegex.exec(stringForPart)[2];\n // Find the corresponding attribute\n // All bound attributes have had a suffix added in\n // TemplateResult#getHTML to opt out of special attribute\n // handling. To look up the attribute value we also need to add\n // the suffix.\n const attributeLookupName = name.toLowerCase() + boundAttributeSuffix;\n const attributeValue = node.getAttribute(attributeLookupName);\n node.removeAttribute(attributeLookupName);\n const statics = attributeValue.split(markerRegex);\n this.parts.push({ type: 'attribute', index, name, strings: statics });\n partIndex += statics.length - 1;\n }\n }\n if (node.tagName === 'TEMPLATE') {\n stack.push(node);\n walker.currentNode = node.content;\n }\n }\n else if (node.nodeType === 3 /* Node.TEXT_NODE */) {\n const data = node.data;\n if (data.indexOf(marker) >= 0) {\n const parent = node.parentNode;\n const strings = data.split(markerRegex);\n const lastIndex = strings.length - 1;\n // Generate a new text node for each literal section\n // These nodes are also used as the markers for node parts\n for (let i = 0; i < lastIndex; i++) {\n let insert;\n let s = strings[i];\n if (s === '') {\n insert = createMarker();\n }\n else {\n const match = lastAttributeNameRegex.exec(s);\n if (match !== null && endsWith(match[2], boundAttributeSuffix)) {\n s = s.slice(0, match.index) + match[1] +\n match[2].slice(0, -boundAttributeSuffix.length) + match[3];\n }\n insert = document.createTextNode(s);\n }\n parent.insertBefore(insert, node);\n this.parts.push({ type: 'node', index: ++index });\n }\n // If there's no text, we must insert a comment to mark our place.\n // Else, we can trust it will stick around after cloning.\n if (strings[lastIndex] === '') {\n parent.insertBefore(createMarker(), node);\n nodesToRemove.push(node);\n }\n else {\n node.data = strings[lastIndex];\n }\n // We have a part for each match found\n partIndex += lastIndex;\n }\n }\n else if (node.nodeType === 8 /* Node.COMMENT_NODE */) {\n if (node.data === marker) {\n const parent = node.parentNode;\n // Add a new marker node to be the startNode of the Part if any of\n // the following are true:\n // * We don't have a previousSibling\n // * The previousSibling is already the start of a previous part\n if (node.previousSibling === null || index === lastPartIndex) {\n index++;\n parent.insertBefore(createMarker(), node);\n }\n lastPartIndex = index;\n this.parts.push({ type: 'node', index });\n // If we don't have a nextSibling, keep this node so we have an end.\n // Else, we can remove it to save future costs.\n if (node.nextSibling === null) {\n node.data = '';\n }\n else {\n nodesToRemove.push(node);\n index--;\n }\n partIndex++;\n }\n else {\n let i = -1;\n while ((i = node.data.indexOf(marker, i + 1)) !== -1) {\n // Comment node has a binding marker inside, make an inactive part\n // The binding won't work, but subsequent bindings will\n // TODO (justinfagnani): consider whether it's even worth it to\n // make bindings in comments work\n this.parts.push({ type: 'node', index: -1 });\n partIndex++;\n }\n }\n }\n }\n // Remove text binding nodes after the walk to not disturb the TreeWalker\n for (const n of nodesToRemove) {\n n.parentNode.removeChild(n);\n }\n }\n}\nconst endsWith = (str, suffix) => {\n const index = str.length - suffix.length;\n return index >= 0 && str.slice(index) === suffix;\n};\nconst isTemplatePartActive = (part) => part.index !== -1;\n// Allows `document.createComment('')` to be renamed for a\n// small manual size-savings.\nconst createMarker = () => document.createComment('');\n/**\n * This regex extracts the attribute name preceding an attribute-position\n * expression. It does this by matching the syntax allowed for attributes\n * against the string literal directly preceding the expression, assuming that\n * the expression is in an attribute-value position.\n *\n * See attributes in the HTML spec:\n * https://www.w3.org/TR/html5/syntax.html#elements-attributes\n *\n * \" \\x09\\x0a\\x0c\\x0d\" are HTML space characters:\n * https://www.w3.org/TR/html5/infrastructure.html#space-characters\n *\n * \"\\0-\\x1F\\x7F-\\x9F\" are Unicode control characters, which includes every\n * space character except \" \".\n *\n * So an attribute is:\n * * The name: any character except a control character, space character, ('),\n * (\"), \">\", \"=\", or \"/\"\n * * Followed by zero or more space characters\n * * Followed by \"=\"\n * * Followed by zero or more space characters\n * * Followed by:\n * * Any character except space, ('), (\"), \"<\", \">\", \"=\", (`), or\n * * (\") then any non-(\"), or\n * * (') then any non-(')\n */\nconst lastAttributeNameRegex = \n// eslint-disable-next-line no-control-regex\n/([ \\x09\\x0a\\x0c\\x0d])([^\\0-\\x1F\\x7F-\\x9F \"'>=/]+)([ \\x09\\x0a\\x0c\\x0d]*=[ \\x09\\x0a\\x0c\\x0d]*(?:[^ \\x09\\x0a\\x0c\\x0d\"'`<>=]*|\"[^\"]*|'[^']*))$/;\n//# sourceMappingURL=template.js.map\n\n//# sourceURL=webpack:///./node_modules/lit-element/node_modules/lit-html/lib/template.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/lit-element/node_modules/lit-html/lit-html.js":
|
|
/*!********************************************************************!*\
|
|
!*** ./node_modules/lit-element/node_modules/lit-html/lit-html.js ***!
|
|
\********************************************************************/
|
|
/*! exports provided: DefaultTemplateProcessor, defaultTemplateProcessor, directive, isDirective, removeNodes, reparentNodes, noChange, nothing, AttributeCommitter, AttributePart, BooleanAttributePart, EventPart, isIterable, isPrimitive, NodePart, PropertyCommitter, PropertyPart, parts, render, templateCaches, templateFactory, TemplateInstance, SVGTemplateResult, TemplateResult, createMarker, isTemplatePartActive, Template, html, svg */
|
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"html\", function() { return html; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"svg\", function() { return svg; });\n/* harmony import */ var _lib_default_template_processor_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./lib/default-template-processor.js */ \"./node_modules/lit-element/node_modules/lit-html/lib/default-template-processor.js\");\n/* harmony import */ var _lib_template_result_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./lib/template-result.js */ \"./node_modules/lit-element/node_modules/lit-html/lib/template-result.js\");\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"DefaultTemplateProcessor\", function() { return _lib_default_template_processor_js__WEBPACK_IMPORTED_MODULE_0__[\"DefaultTemplateProcessor\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"defaultTemplateProcessor\", function() { return _lib_default_template_processor_js__WEBPACK_IMPORTED_MODULE_0__[\"defaultTemplateProcessor\"]; });\n\n/* harmony import */ var _lib_directive_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./lib/directive.js */ \"./node_modules/lit-element/node_modules/lit-html/lib/directive.js\");\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"directive\", function() { return _lib_directive_js__WEBPACK_IMPORTED_MODULE_2__[\"directive\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"isDirective\", function() { return _lib_directive_js__WEBPACK_IMPORTED_MODULE_2__[\"isDirective\"]; });\n\n/* harmony import */ var _lib_dom_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./lib/dom.js */ \"./node_modules/lit-element/node_modules/lit-html/lib/dom.js\");\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"removeNodes\", function() { return _lib_dom_js__WEBPACK_IMPORTED_MODULE_3__[\"removeNodes\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"reparentNodes\", function() { return _lib_dom_js__WEBPACK_IMPORTED_MODULE_3__[\"reparentNodes\"]; });\n\n/* harmony import */ var _lib_part_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./lib/part.js */ \"./node_modules/lit-element/node_modules/lit-html/lib/part.js\");\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"noChange\", function() { return _lib_part_js__WEBPACK_IMPORTED_MODULE_4__[\"noChange\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"nothing\", function() { return _lib_part_js__WEBPACK_IMPORTED_MODULE_4__[\"nothing\"]; });\n\n/* harmony import */ var _lib_parts_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./lib/parts.js */ \"./node_modules/lit-element/node_modules/lit-html/lib/parts.js\");\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"AttributeCommitter\", function() { return _lib_parts_js__WEBPACK_IMPORTED_MODULE_5__[\"AttributeCommitter\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"AttributePart\", function() { return _lib_parts_js__WEBPACK_IMPORTED_MODULE_5__[\"AttributePart\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"BooleanAttributePart\", function() { return _lib_parts_js__WEBPACK_IMPORTED_MODULE_5__[\"BooleanAttributePart\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"EventPart\", function() { return _lib_parts_js__WEBPACK_IMPORTED_MODULE_5__[\"EventPart\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"isIterable\", function() { return _lib_parts_js__WEBPACK_IMPORTED_MODULE_5__[\"isIterable\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"isPrimitive\", function() { return _lib_parts_js__WEBPACK_IMPORTED_MODULE_5__[\"isPrimitive\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"NodePart\", function() { return _lib_parts_js__WEBPACK_IMPORTED_MODULE_5__[\"NodePart\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"PropertyCommitter\", function() { return _lib_parts_js__WEBPACK_IMPORTED_MODULE_5__[\"PropertyCommitter\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"PropertyPart\", function() { return _lib_parts_js__WEBPACK_IMPORTED_MODULE_5__[\"PropertyPart\"]; });\n\n/* harmony import */ var _lib_render_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./lib/render.js */ \"./node_modules/lit-element/node_modules/lit-html/lib/render.js\");\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"parts\", function() { return _lib_render_js__WEBPACK_IMPORTED_MODULE_6__[\"parts\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"render\", function() { return _lib_render_js__WEBPACK_IMPORTED_MODULE_6__[\"render\"]; });\n\n/* harmony import */ var _lib_template_factory_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./lib/template-factory.js */ \"./node_modules/lit-element/node_modules/lit-html/lib/template-factory.js\");\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"templateCaches\", function() { return _lib_template_factory_js__WEBPACK_IMPORTED_MODULE_7__[\"templateCaches\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"templateFactory\", function() { return _lib_template_factory_js__WEBPACK_IMPORTED_MODULE_7__[\"templateFactory\"]; });\n\n/* harmony import */ var _lib_template_instance_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ./lib/template-instance.js */ \"./node_modules/lit-element/node_modules/lit-html/lib/template-instance.js\");\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"TemplateInstance\", function() { return _lib_template_instance_js__WEBPACK_IMPORTED_MODULE_8__[\"TemplateInstance\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"SVGTemplateResult\", function() { return _lib_template_result_js__WEBPACK_IMPORTED_MODULE_1__[\"SVGTemplateResult\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"TemplateResult\", function() { return _lib_template_result_js__WEBPACK_IMPORTED_MODULE_1__[\"TemplateResult\"]; });\n\n/* harmony import */ var _lib_template_js__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ./lib/template.js */ \"./node_modules/lit-element/node_modules/lit-html/lib/template.js\");\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"createMarker\", function() { return _lib_template_js__WEBPACK_IMPORTED_MODULE_9__[\"createMarker\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"isTemplatePartActive\", function() { return _lib_template_js__WEBPACK_IMPORTED_MODULE_9__[\"isTemplatePartActive\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"Template\", function() { return _lib_template_js__WEBPACK_IMPORTED_MODULE_9__[\"Template\"]; });\n\n/**\n * @license\n * Copyright (c) 2017 The Polymer Project Authors. All rights reserved.\n * This code may only be used under the BSD style license found at\n * http://polymer.github.io/LICENSE.txt\n * The complete set of authors may be found at\n * http://polymer.github.io/AUTHORS.txt\n * The complete set of contributors may be found at\n * http://polymer.github.io/CONTRIBUTORS.txt\n * Code distributed by Google as part of the polymer project is also\n * subject to an additional IP rights grant found at\n * http://polymer.github.io/PATENTS.txt\n */\n/**\n *\n * Main lit-html module.\n *\n * Main exports:\n *\n * - [[html]]\n * - [[svg]]\n * - [[render]]\n *\n * @module lit-html\n * @preferred\n */\n/**\n * Do not remove this comment; it keeps typedoc from misplacing the module\n * docs.\n */\n\n\n\n\n// TODO(justinfagnani): remove line when we get NodePart moving methods\n\n\n\n\n\n\n\n\n// IMPORTANT: do not change the property name or the assignment expression.\n// This line will be used in regexes to search for lit-html usage.\n// TODO(justinfagnani): inject version number at build time\nif (typeof window !== 'undefined') {\n (window['litHtmlVersions'] || (window['litHtmlVersions'] = [])).push('1.2.1');\n}\n/**\n * Interprets a template literal as an HTML template that can efficiently\n * render to and update a container.\n */\nconst html = (strings, ...values) => new _lib_template_result_js__WEBPACK_IMPORTED_MODULE_1__[\"TemplateResult\"](strings, values, 'html', _lib_default_template_processor_js__WEBPACK_IMPORTED_MODULE_0__[\"defaultTemplateProcessor\"]);\n/**\n * Interprets a template literal as an SVG template that can efficiently\n * render to and update a container.\n */\nconst svg = (strings, ...values) => new _lib_template_result_js__WEBPACK_IMPORTED_MODULE_1__[\"SVGTemplateResult\"](strings, values, 'svg', _lib_default_template_processor_js__WEBPACK_IMPORTED_MODULE_0__[\"defaultTemplateProcessor\"]);\n//# sourceMappingURL=lit-html.js.map\n\n//# sourceURL=webpack:///./node_modules/lit-element/node_modules/lit-html/lit-html.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/lit-html/directives/style-map.js":
|
|
/*!*******************************************************!*\
|
|
!*** ./node_modules/lit-html/directives/style-map.js ***!
|
|
\*******************************************************/
|
|
/*! exports provided: styleMap */
|
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"styleMap\", function() { return styleMap; });\n/* harmony import */ var _lit_html_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../lit-html.js */ \"./node_modules/lit-html/lit-html.js\");\n/**\n * @license\n * Copyright (c) 2018 The Polymer Project Authors. All rights reserved.\n * This code may only be used under the BSD style license found at\n * http://polymer.github.io/LICENSE.txt\n * The complete set of authors may be found at\n * http://polymer.github.io/AUTHORS.txt\n * The complete set of contributors may be found at\n * http://polymer.github.io/CONTRIBUTORS.txt\n * Code distributed by Google as part of the polymer project is also\n * subject to an additional IP rights grant found at\n * http://polymer.github.io/PATENTS.txt\n */\n\n/**\n * Stores the StyleInfo object applied to a given AttributePart.\n * Used to unset existing values when a new StyleInfo object is applied.\n */\nconst previousStylePropertyCache = new WeakMap();\n/**\n * A directive that applies CSS properties to an element.\n *\n * `styleMap` can only be used in the `style` attribute and must be the only\n * expression in the attribute. It takes the property names in the `styleInfo`\n * object and adds the property values as CSS properties. Property names with\n * dashes (`-`) are assumed to be valid CSS property names and set on the\n * element's style object using `setProperty()`. Names without dashes are\n * assumed to be camelCased JavaScript property names and set on the element's\n * style object using property assignment, allowing the style object to\n * translate JavaScript-style names to CSS property names.\n *\n * For example `styleMap({backgroundColor: 'red', 'border-top': '5px', '--size':\n * '0'})` sets the `background-color`, `border-top` and `--size` properties.\n *\n * @param styleInfo {StyleInfo}\n */\nconst styleMap = Object(_lit_html_js__WEBPACK_IMPORTED_MODULE_0__[\"directive\"])((styleInfo) => (part) => {\n if (!(part instanceof _lit_html_js__WEBPACK_IMPORTED_MODULE_0__[\"AttributePart\"]) || (part instanceof _lit_html_js__WEBPACK_IMPORTED_MODULE_0__[\"PropertyPart\"]) ||\n part.committer.name !== 'style' || part.committer.parts.length > 1) {\n throw new Error('The `styleMap` directive must be used in the style attribute ' +\n 'and must be the only part in the attribute.');\n }\n const { committer } = part;\n const { style } = committer.element;\n let previousStyleProperties = previousStylePropertyCache.get(part);\n if (previousStyleProperties === undefined) {\n // Write static styles once\n style.cssText = committer.strings.join(' ');\n previousStylePropertyCache.set(part, previousStyleProperties = new Set());\n }\n // Remove old properties that no longer exist in styleInfo\n // We use forEach() instead of for-of so that re don't require down-level\n // iteration.\n previousStyleProperties.forEach((name) => {\n if (!(name in styleInfo)) {\n previousStyleProperties.delete(name);\n if (name.indexOf('-') === -1) {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n style[name] = null;\n }\n else {\n style.removeProperty(name);\n }\n }\n });\n // Add or update properties\n for (const name in styleInfo) {\n previousStyleProperties.add(name);\n if (name.indexOf('-') === -1) {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n style[name] = styleInfo[name];\n }\n else {\n style.setProperty(name, styleInfo[name]);\n }\n }\n});\n//# sourceMappingURL=style-map.js.map\n\n//# sourceURL=webpack:///./node_modules/lit-html/directives/style-map.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/lit-html/lib/default-template-processor.js":
|
|
/*!*****************************************************************!*\
|
|
!*** ./node_modules/lit-html/lib/default-template-processor.js ***!
|
|
\*****************************************************************/
|
|
/*! exports provided: DefaultTemplateProcessor, defaultTemplateProcessor */
|
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"DefaultTemplateProcessor\", function() { return DefaultTemplateProcessor; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"defaultTemplateProcessor\", function() { return defaultTemplateProcessor; });\n/* harmony import */ var _parts_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./parts.js */ \"./node_modules/lit-html/lib/parts.js\");\n/**\n * @license\n * Copyright (c) 2017 The Polymer Project Authors. All rights reserved.\n * This code may only be used under the BSD style license found at\n * http://polymer.github.io/LICENSE.txt\n * The complete set of authors may be found at\n * http://polymer.github.io/AUTHORS.txt\n * The complete set of contributors may be found at\n * http://polymer.github.io/CONTRIBUTORS.txt\n * Code distributed by Google as part of the polymer project is also\n * subject to an additional IP rights grant found at\n * http://polymer.github.io/PATENTS.txt\n */\n\n/**\n * Creates Parts when a template is instantiated.\n */\nclass DefaultTemplateProcessor {\n /**\n * Create parts for an attribute-position binding, given the event, attribute\n * name, and string literals.\n *\n * @param element The element containing the binding\n * @param name The attribute name\n * @param strings The string literals. There are always at least two strings,\n * event for fully-controlled bindings with a single expression.\n */\n handleAttributeExpressions(element, name, strings, options) {\n const prefix = name[0];\n if (prefix === '.') {\n const committer = new _parts_js__WEBPACK_IMPORTED_MODULE_0__[\"PropertyCommitter\"](element, name.slice(1), strings);\n return committer.parts;\n }\n if (prefix === '@') {\n return [new _parts_js__WEBPACK_IMPORTED_MODULE_0__[\"EventPart\"](element, name.slice(1), options.eventContext)];\n }\n if (prefix === '?') {\n return [new _parts_js__WEBPACK_IMPORTED_MODULE_0__[\"BooleanAttributePart\"](element, name.slice(1), strings)];\n }\n const committer = new _parts_js__WEBPACK_IMPORTED_MODULE_0__[\"AttributeCommitter\"](element, name, strings);\n return committer.parts;\n }\n /**\n * Create parts for a text-position binding.\n * @param templateFactory\n */\n handleTextExpression(options) {\n return new _parts_js__WEBPACK_IMPORTED_MODULE_0__[\"NodePart\"](options);\n }\n}\nconst defaultTemplateProcessor = new DefaultTemplateProcessor();\n//# sourceMappingURL=default-template-processor.js.map\n\n//# sourceURL=webpack:///./node_modules/lit-html/lib/default-template-processor.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/lit-html/lib/directive.js":
|
|
/*!************************************************!*\
|
|
!*** ./node_modules/lit-html/lib/directive.js ***!
|
|
\************************************************/
|
|
/*! exports provided: directive, isDirective */
|
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"directive\", function() { return directive; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"isDirective\", function() { return isDirective; });\n/**\n * @license\n * Copyright (c) 2017 The Polymer Project Authors. All rights reserved.\n * This code may only be used under the BSD style license found at\n * http://polymer.github.io/LICENSE.txt\n * The complete set of authors may be found at\n * http://polymer.github.io/AUTHORS.txt\n * The complete set of contributors may be found at\n * http://polymer.github.io/CONTRIBUTORS.txt\n * Code distributed by Google as part of the polymer project is also\n * subject to an additional IP rights grant found at\n * http://polymer.github.io/PATENTS.txt\n */\nconst directives = new WeakMap();\n/**\n * Brands a function as a directive factory function so that lit-html will call\n * the function during template rendering, rather than passing as a value.\n *\n * A _directive_ is a function that takes a Part as an argument. It has the\n * signature: `(part: Part) => void`.\n *\n * A directive _factory_ is a function that takes arguments for data and\n * configuration and returns a directive. Users of directive usually refer to\n * the directive factory as the directive. For example, \"The repeat directive\".\n *\n * Usually a template author will invoke a directive factory in their template\n * with relevant arguments, which will then return a directive function.\n *\n * Here's an example of using the `repeat()` directive factory that takes an\n * array and a function to render an item:\n *\n * ```js\n * html`<ul><${repeat(items, (item) => html`<li>${item}</li>`)}</ul>`\n * ```\n *\n * When `repeat` is invoked, it returns a directive function that closes over\n * `items` and the template function. When the outer template is rendered, the\n * return directive function is called with the Part for the expression.\n * `repeat` then performs it's custom logic to render multiple items.\n *\n * @param f The directive factory function. Must be a function that returns a\n * function of the signature `(part: Part) => void`. The returned function will\n * be called with the part object.\n *\n * @example\n *\n * import {directive, html} from 'lit-html';\n *\n * const immutable = directive((v) => (part) => {\n * if (part.value !== v) {\n * part.setValue(v)\n * }\n * });\n */\nconst directive = (f) => ((...args) => {\n const d = f(...args);\n directives.set(d, true);\n return d;\n});\nconst isDirective = (o) => {\n return typeof o === 'function' && directives.has(o);\n};\n//# sourceMappingURL=directive.js.map\n\n//# sourceURL=webpack:///./node_modules/lit-html/lib/directive.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/lit-html/lib/dom.js":
|
|
/*!******************************************!*\
|
|
!*** ./node_modules/lit-html/lib/dom.js ***!
|
|
\******************************************/
|
|
/*! exports provided: isCEPolyfill, reparentNodes, removeNodes */
|
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"isCEPolyfill\", function() { return isCEPolyfill; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"reparentNodes\", function() { return reparentNodes; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"removeNodes\", function() { return removeNodes; });\n/**\n * @license\n * Copyright (c) 2017 The Polymer Project Authors. All rights reserved.\n * This code may only be used under the BSD style license found at\n * http://polymer.github.io/LICENSE.txt\n * The complete set of authors may be found at\n * http://polymer.github.io/AUTHORS.txt\n * The complete set of contributors may be found at\n * http://polymer.github.io/CONTRIBUTORS.txt\n * Code distributed by Google as part of the polymer project is also\n * subject to an additional IP rights grant found at\n * http://polymer.github.io/PATENTS.txt\n */\n/**\n * True if the custom elements polyfill is in use.\n */\nconst isCEPolyfill = typeof window !== 'undefined' &&\n window.customElements != null &&\n window.customElements.polyfillWrapFlushCallback !==\n undefined;\n/**\n * Reparents nodes, starting from `start` (inclusive) to `end` (exclusive),\n * into another container (could be the same container), before `before`. If\n * `before` is null, it appends the nodes to the container.\n */\nconst reparentNodes = (container, start, end = null, before = null) => {\n while (start !== end) {\n const n = start.nextSibling;\n container.insertBefore(start, before);\n start = n;\n }\n};\n/**\n * Removes nodes, starting from `start` (inclusive) to `end` (exclusive), from\n * `container`.\n */\nconst removeNodes = (container, start, end = null) => {\n while (start !== end) {\n const n = start.nextSibling;\n container.removeChild(start);\n start = n;\n }\n};\n//# sourceMappingURL=dom.js.map\n\n//# sourceURL=webpack:///./node_modules/lit-html/lib/dom.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/lit-html/lib/part.js":
|
|
/*!*******************************************!*\
|
|
!*** ./node_modules/lit-html/lib/part.js ***!
|
|
\*******************************************/
|
|
/*! exports provided: noChange, nothing */
|
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"noChange\", function() { return noChange; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"nothing\", function() { return nothing; });\n/**\n * @license\n * Copyright (c) 2018 The Polymer Project Authors. All rights reserved.\n * This code may only be used under the BSD style license found at\n * http://polymer.github.io/LICENSE.txt\n * The complete set of authors may be found at\n * http://polymer.github.io/AUTHORS.txt\n * The complete set of contributors may be found at\n * http://polymer.github.io/CONTRIBUTORS.txt\n * Code distributed by Google as part of the polymer project is also\n * subject to an additional IP rights grant found at\n * http://polymer.github.io/PATENTS.txt\n */\n/**\n * A sentinel value that signals that a value was handled by a directive and\n * should not be written to the DOM.\n */\nconst noChange = {};\n/**\n * A sentinel value that signals a NodePart to fully clear its content.\n */\nconst nothing = {};\n//# sourceMappingURL=part.js.map\n\n//# sourceURL=webpack:///./node_modules/lit-html/lib/part.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/lit-html/lib/parts.js":
|
|
/*!********************************************!*\
|
|
!*** ./node_modules/lit-html/lib/parts.js ***!
|
|
\********************************************/
|
|
/*! exports provided: isPrimitive, isIterable, AttributeCommitter, AttributePart, NodePart, BooleanAttributePart, PropertyCommitter, PropertyPart, EventPart */
|
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"isPrimitive\", function() { return isPrimitive; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"isIterable\", function() { return isIterable; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"AttributeCommitter\", function() { return AttributeCommitter; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"AttributePart\", function() { return AttributePart; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"NodePart\", function() { return NodePart; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"BooleanAttributePart\", function() { return BooleanAttributePart; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"PropertyCommitter\", function() { return PropertyCommitter; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"PropertyPart\", function() { return PropertyPart; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"EventPart\", function() { return EventPart; });\n/* harmony import */ var _directive_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./directive.js */ \"./node_modules/lit-html/lib/directive.js\");\n/* harmony import */ var _dom_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./dom.js */ \"./node_modules/lit-html/lib/dom.js\");\n/* harmony import */ var _part_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./part.js */ \"./node_modules/lit-html/lib/part.js\");\n/* harmony import */ var _template_instance_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./template-instance.js */ \"./node_modules/lit-html/lib/template-instance.js\");\n/* harmony import */ var _template_result_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./template-result.js */ \"./node_modules/lit-html/lib/template-result.js\");\n/* harmony import */ var _template_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./template.js */ \"./node_modules/lit-html/lib/template.js\");\n/**\n * @license\n * Copyright (c) 2017 The Polymer Project Authors. All rights reserved.\n * This code may only be used under the BSD style license found at\n * http://polymer.github.io/LICENSE.txt\n * The complete set of authors may be found at\n * http://polymer.github.io/AUTHORS.txt\n * The complete set of contributors may be found at\n * http://polymer.github.io/CONTRIBUTORS.txt\n * Code distributed by Google as part of the polymer project is also\n * subject to an additional IP rights grant found at\n * http://polymer.github.io/PATENTS.txt\n */\n/**\n * @module lit-html\n */\n\n\n\n\n\n\nconst isPrimitive = (value) => {\n return (value === null ||\n !(typeof value === 'object' || typeof value === 'function'));\n};\nconst isIterable = (value) => {\n return Array.isArray(value) ||\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n !!(value && value[Symbol.iterator]);\n};\n/**\n * Writes attribute values to the DOM for a group of AttributeParts bound to a\n * single attribute. The value is only set once even if there are multiple parts\n * for an attribute.\n */\nclass AttributeCommitter {\n constructor(element, name, strings) {\n this.dirty = true;\n this.element = element;\n this.name = name;\n this.strings = strings;\n this.parts = [];\n for (let i = 0; i < strings.length - 1; i++) {\n this.parts[i] = this._createPart();\n }\n }\n /**\n * Creates a single part. Override this to create a differnt type of part.\n */\n _createPart() {\n return new AttributePart(this);\n }\n _getValue() {\n const strings = this.strings;\n const l = strings.length - 1;\n let text = '';\n for (let i = 0; i < l; i++) {\n text += strings[i];\n const part = this.parts[i];\n if (part !== undefined) {\n const v = part.value;\n if (isPrimitive(v) || !isIterable(v)) {\n text += typeof v === 'string' ? v : String(v);\n }\n else {\n for (const t of v) {\n text += typeof t === 'string' ? t : String(t);\n }\n }\n }\n }\n text += strings[l];\n return text;\n }\n commit() {\n if (this.dirty) {\n this.dirty = false;\n this.element.setAttribute(this.name, this._getValue());\n }\n }\n}\n/**\n * A Part that controls all or part of an attribute value.\n */\nclass AttributePart {\n constructor(committer) {\n this.value = undefined;\n this.committer = committer;\n }\n setValue(value) {\n if (value !== _part_js__WEBPACK_IMPORTED_MODULE_2__[\"noChange\"] && (!isPrimitive(value) || value !== this.value)) {\n this.value = value;\n // If the value is a not a directive, dirty the committer so that it'll\n // call setAttribute. If the value is a directive, it'll dirty the\n // committer if it calls setValue().\n if (!Object(_directive_js__WEBPACK_IMPORTED_MODULE_0__[\"isDirective\"])(value)) {\n this.committer.dirty = true;\n }\n }\n }\n commit() {\n while (Object(_directive_js__WEBPACK_IMPORTED_MODULE_0__[\"isDirective\"])(this.value)) {\n const directive = this.value;\n this.value = _part_js__WEBPACK_IMPORTED_MODULE_2__[\"noChange\"];\n directive(this);\n }\n if (this.value === _part_js__WEBPACK_IMPORTED_MODULE_2__[\"noChange\"]) {\n return;\n }\n this.committer.commit();\n }\n}\n/**\n * A Part that controls a location within a Node tree. Like a Range, NodePart\n * has start and end locations and can set and update the Nodes between those\n * locations.\n *\n * NodeParts support several value types: primitives, Nodes, TemplateResults,\n * as well as arrays and iterables of those types.\n */\nclass NodePart {\n constructor(options) {\n this.value = undefined;\n this.__pendingValue = undefined;\n this.options = options;\n }\n /**\n * Appends this part into a container.\n *\n * This part must be empty, as its contents are not automatically moved.\n */\n appendInto(container) {\n this.startNode = container.appendChild(Object(_template_js__WEBPACK_IMPORTED_MODULE_5__[\"createMarker\"])());\n this.endNode = container.appendChild(Object(_template_js__WEBPACK_IMPORTED_MODULE_5__[\"createMarker\"])());\n }\n /**\n * Inserts this part after the `ref` node (between `ref` and `ref`'s next\n * sibling). Both `ref` and its next sibling must be static, unchanging nodes\n * such as those that appear in a literal section of a template.\n *\n * This part must be empty, as its contents are not automatically moved.\n */\n insertAfterNode(ref) {\n this.startNode = ref;\n this.endNode = ref.nextSibling;\n }\n /**\n * Appends this part into a parent part.\n *\n * This part must be empty, as its contents are not automatically moved.\n */\n appendIntoPart(part) {\n part.__insert(this.startNode = Object(_template_js__WEBPACK_IMPORTED_MODULE_5__[\"createMarker\"])());\n part.__insert(this.endNode = Object(_template_js__WEBPACK_IMPORTED_MODULE_5__[\"createMarker\"])());\n }\n /**\n * Inserts this part after the `ref` part.\n *\n * This part must be empty, as its contents are not automatically moved.\n */\n insertAfterPart(ref) {\n ref.__insert(this.startNode = Object(_template_js__WEBPACK_IMPORTED_MODULE_5__[\"createMarker\"])());\n this.endNode = ref.endNode;\n ref.endNode = this.startNode;\n }\n setValue(value) {\n this.__pendingValue = value;\n }\n commit() {\n if (this.startNode.parentNode === null) {\n return;\n }\n while (Object(_directive_js__WEBPACK_IMPORTED_MODULE_0__[\"isDirective\"])(this.__pendingValue)) {\n const directive = this.__pendingValue;\n this.__pendingValue = _part_js__WEBPACK_IMPORTED_MODULE_2__[\"noChange\"];\n directive(this);\n }\n const value = this.__pendingValue;\n if (value === _part_js__WEBPACK_IMPORTED_MODULE_2__[\"noChange\"]) {\n return;\n }\n if (isPrimitive(value)) {\n if (value !== this.value) {\n this.__commitText(value);\n }\n }\n else if (value instanceof _template_result_js__WEBPACK_IMPORTED_MODULE_4__[\"TemplateResult\"]) {\n this.__commitTemplateResult(value);\n }\n else if (value instanceof Node) {\n this.__commitNode(value);\n }\n else if (isIterable(value)) {\n this.__commitIterable(value);\n }\n else if (value === _part_js__WEBPACK_IMPORTED_MODULE_2__[\"nothing\"]) {\n this.value = _part_js__WEBPACK_IMPORTED_MODULE_2__[\"nothing\"];\n this.clear();\n }\n else {\n // Fallback, will render the string representation\n this.__commitText(value);\n }\n }\n __insert(node) {\n this.endNode.parentNode.insertBefore(node, this.endNode);\n }\n __commitNode(value) {\n if (this.value === value) {\n return;\n }\n this.clear();\n this.__insert(value);\n this.value = value;\n }\n __commitText(value) {\n const node = this.startNode.nextSibling;\n value = value == null ? '' : value;\n // If `value` isn't already a string, we explicitly convert it here in case\n // it can't be implicitly converted - i.e. it's a symbol.\n const valueAsString = typeof value === 'string' ? value : String(value);\n if (node === this.endNode.previousSibling &&\n node.nodeType === 3 /* Node.TEXT_NODE */) {\n // If we only have a single text node between the markers, we can just\n // set its value, rather than replacing it.\n // TODO(justinfagnani): Can we just check if this.value is primitive?\n node.data = valueAsString;\n }\n else {\n this.__commitNode(document.createTextNode(valueAsString));\n }\n this.value = value;\n }\n __commitTemplateResult(value) {\n const template = this.options.templateFactory(value);\n if (this.value instanceof _template_instance_js__WEBPACK_IMPORTED_MODULE_3__[\"TemplateInstance\"] &&\n this.value.template === template) {\n this.value.update(value.values);\n }\n else {\n // Make sure we propagate the template processor from the TemplateResult\n // so that we use its syntax extension, etc. The template factory comes\n // from the render function options so that it can control template\n // caching and preprocessing.\n const instance = new _template_instance_js__WEBPACK_IMPORTED_MODULE_3__[\"TemplateInstance\"](template, value.processor, this.options);\n const fragment = instance._clone();\n instance.update(value.values);\n this.__commitNode(fragment);\n this.value = instance;\n }\n }\n __commitIterable(value) {\n // For an Iterable, we create a new InstancePart per item, then set its\n // value to the item. This is a little bit of overhead for every item in\n // an Iterable, but it lets us recurse easily and efficiently update Arrays\n // of TemplateResults that will be commonly returned from expressions like:\n // array.map((i) => html`${i}`), by reusing existing TemplateInstances.\n // If _value is an array, then the previous render was of an\n // iterable and _value will contain the NodeParts from the previous\n // render. If _value is not an array, clear this part and make a new\n // array for NodeParts.\n if (!Array.isArray(this.value)) {\n this.value = [];\n this.clear();\n }\n // Lets us keep track of how many items we stamped so we can clear leftover\n // items from a previous render\n const itemParts = this.value;\n let partIndex = 0;\n let itemPart;\n for (const item of value) {\n // Try to reuse an existing part\n itemPart = itemParts[partIndex];\n // If no existing part, create a new one\n if (itemPart === undefined) {\n itemPart = new NodePart(this.options);\n itemParts.push(itemPart);\n if (partIndex === 0) {\n itemPart.appendIntoPart(this);\n }\n else {\n itemPart.insertAfterPart(itemParts[partIndex - 1]);\n }\n }\n itemPart.setValue(item);\n itemPart.commit();\n partIndex++;\n }\n if (partIndex < itemParts.length) {\n // Truncate the parts array so _value reflects the current state\n itemParts.length = partIndex;\n this.clear(itemPart && itemPart.endNode);\n }\n }\n clear(startNode = this.startNode) {\n Object(_dom_js__WEBPACK_IMPORTED_MODULE_1__[\"removeNodes\"])(this.startNode.parentNode, startNode.nextSibling, this.endNode);\n }\n}\n/**\n * Implements a boolean attribute, roughly as defined in the HTML\n * specification.\n *\n * If the value is truthy, then the attribute is present with a value of\n * ''. If the value is falsey, the attribute is removed.\n */\nclass BooleanAttributePart {\n constructor(element, name, strings) {\n this.value = undefined;\n this.__pendingValue = undefined;\n if (strings.length !== 2 || strings[0] !== '' || strings[1] !== '') {\n throw new Error('Boolean attributes can only contain a single expression');\n }\n this.element = element;\n this.name = name;\n this.strings = strings;\n }\n setValue(value) {\n this.__pendingValue = value;\n }\n commit() {\n while (Object(_directive_js__WEBPACK_IMPORTED_MODULE_0__[\"isDirective\"])(this.__pendingValue)) {\n const directive = this.__pendingValue;\n this.__pendingValue = _part_js__WEBPACK_IMPORTED_MODULE_2__[\"noChange\"];\n directive(this);\n }\n if (this.__pendingValue === _part_js__WEBPACK_IMPORTED_MODULE_2__[\"noChange\"]) {\n return;\n }\n const value = !!this.__pendingValue;\n if (this.value !== value) {\n if (value) {\n this.element.setAttribute(this.name, '');\n }\n else {\n this.element.removeAttribute(this.name);\n }\n this.value = value;\n }\n this.__pendingValue = _part_js__WEBPACK_IMPORTED_MODULE_2__[\"noChange\"];\n }\n}\n/**\n * Sets attribute values for PropertyParts, so that the value is only set once\n * even if there are multiple parts for a property.\n *\n * If an expression controls the whole property value, then the value is simply\n * assigned to the property under control. If there are string literals or\n * multiple expressions, then the strings are expressions are interpolated into\n * a string first.\n */\nclass PropertyCommitter extends AttributeCommitter {\n constructor(element, name, strings) {\n super(element, name, strings);\n this.single =\n (strings.length === 2 && strings[0] === '' && strings[1] === '');\n }\n _createPart() {\n return new PropertyPart(this);\n }\n _getValue() {\n if (this.single) {\n return this.parts[0].value;\n }\n return super._getValue();\n }\n commit() {\n if (this.dirty) {\n this.dirty = false;\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n this.element[this.name] = this._getValue();\n }\n }\n}\nclass PropertyPart extends AttributePart {\n}\n// Detect event listener options support. If the `capture` property is read\n// from the options object, then options are supported. If not, then the third\n// argument to add/removeEventListener is interpreted as the boolean capture\n// value so we should only pass the `capture` property.\nlet eventOptionsSupported = false;\n// Wrap into an IIFE because MS Edge <= v41 does not support having try/catch\n// blocks right into the body of a module\n(() => {\n try {\n const options = {\n get capture() {\n eventOptionsSupported = true;\n return false;\n }\n };\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n window.addEventListener('test', options, options);\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n window.removeEventListener('test', options, options);\n }\n catch (_e) {\n // event options not supported\n }\n})();\nclass EventPart {\n constructor(element, eventName, eventContext) {\n this.value = undefined;\n this.__pendingValue = undefined;\n this.element = element;\n this.eventName = eventName;\n this.eventContext = eventContext;\n this.__boundHandleEvent = (e) => this.handleEvent(e);\n }\n setValue(value) {\n this.__pendingValue = value;\n }\n commit() {\n while (Object(_directive_js__WEBPACK_IMPORTED_MODULE_0__[\"isDirective\"])(this.__pendingValue)) {\n const directive = this.__pendingValue;\n this.__pendingValue = _part_js__WEBPACK_IMPORTED_MODULE_2__[\"noChange\"];\n directive(this);\n }\n if (this.__pendingValue === _part_js__WEBPACK_IMPORTED_MODULE_2__[\"noChange\"]) {\n return;\n }\n const newListener = this.__pendingValue;\n const oldListener = this.value;\n const shouldRemoveListener = newListener == null ||\n oldListener != null &&\n (newListener.capture !== oldListener.capture ||\n newListener.once !== oldListener.once ||\n newListener.passive !== oldListener.passive);\n const shouldAddListener = newListener != null && (oldListener == null || shouldRemoveListener);\n if (shouldRemoveListener) {\n this.element.removeEventListener(this.eventName, this.__boundHandleEvent, this.__options);\n }\n if (shouldAddListener) {\n this.__options = getOptions(newListener);\n this.element.addEventListener(this.eventName, this.__boundHandleEvent, this.__options);\n }\n this.value = newListener;\n this.__pendingValue = _part_js__WEBPACK_IMPORTED_MODULE_2__[\"noChange\"];\n }\n handleEvent(event) {\n if (typeof this.value === 'function') {\n this.value.call(this.eventContext || this.element, event);\n }\n else {\n this.value.handleEvent(event);\n }\n }\n}\n// We copy options because of the inconsistent behavior of browsers when reading\n// the third argument of add/removeEventListener. IE11 doesn't support options\n// at all. Chrome 41 only reads `capture` if the argument is an object.\nconst getOptions = (o) => o &&\n (eventOptionsSupported ?\n { capture: o.capture, passive: o.passive, once: o.once } :\n o.capture);\n//# sourceMappingURL=parts.js.map\n\n//# sourceURL=webpack:///./node_modules/lit-html/lib/parts.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/lit-html/lib/render.js":
|
|
/*!*********************************************!*\
|
|
!*** ./node_modules/lit-html/lib/render.js ***!
|
|
\*********************************************/
|
|
/*! exports provided: parts, render */
|
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"parts\", function() { return parts; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"render\", function() { return render; });\n/* harmony import */ var _dom_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./dom.js */ \"./node_modules/lit-html/lib/dom.js\");\n/* harmony import */ var _parts_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./parts.js */ \"./node_modules/lit-html/lib/parts.js\");\n/* harmony import */ var _template_factory_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./template-factory.js */ \"./node_modules/lit-html/lib/template-factory.js\");\n/**\n * @license\n * Copyright (c) 2017 The Polymer Project Authors. All rights reserved.\n * This code may only be used under the BSD style license found at\n * http://polymer.github.io/LICENSE.txt\n * The complete set of authors may be found at\n * http://polymer.github.io/AUTHORS.txt\n * The complete set of contributors may be found at\n * http://polymer.github.io/CONTRIBUTORS.txt\n * Code distributed by Google as part of the polymer project is also\n * subject to an additional IP rights grant found at\n * http://polymer.github.io/PATENTS.txt\n */\n/**\n * @module lit-html\n */\n\n\n\nconst parts = new WeakMap();\n/**\n * Renders a template result or other value to a container.\n *\n * To update a container with new values, reevaluate the template literal and\n * call `render` with the new result.\n *\n * @param result Any value renderable by NodePart - typically a TemplateResult\n * created by evaluating a template tag like `html` or `svg`.\n * @param container A DOM parent to render to. The entire contents are either\n * replaced, or efficiently updated if the same result type was previous\n * rendered there.\n * @param options RenderOptions for the entire render tree rendered to this\n * container. Render options must *not* change between renders to the same\n * container, as those changes will not effect previously rendered DOM.\n */\nconst render = (result, container, options) => {\n let part = parts.get(container);\n if (part === undefined) {\n Object(_dom_js__WEBPACK_IMPORTED_MODULE_0__[\"removeNodes\"])(container, container.firstChild);\n parts.set(container, part = new _parts_js__WEBPACK_IMPORTED_MODULE_1__[\"NodePart\"](Object.assign({ templateFactory: _template_factory_js__WEBPACK_IMPORTED_MODULE_2__[\"templateFactory\"] }, options)));\n part.appendInto(container);\n }\n part.setValue(result);\n part.commit();\n};\n//# sourceMappingURL=render.js.map\n\n//# sourceURL=webpack:///./node_modules/lit-html/lib/render.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/lit-html/lib/template-factory.js":
|
|
/*!*******************************************************!*\
|
|
!*** ./node_modules/lit-html/lib/template-factory.js ***!
|
|
\*******************************************************/
|
|
/*! exports provided: templateFactory, templateCaches */
|
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"templateFactory\", function() { return templateFactory; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"templateCaches\", function() { return templateCaches; });\n/* harmony import */ var _template_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./template.js */ \"./node_modules/lit-html/lib/template.js\");\n/**\n * @license\n * Copyright (c) 2017 The Polymer Project Authors. All rights reserved.\n * This code may only be used under the BSD style license found at\n * http://polymer.github.io/LICENSE.txt\n * The complete set of authors may be found at\n * http://polymer.github.io/AUTHORS.txt\n * The complete set of contributors may be found at\n * http://polymer.github.io/CONTRIBUTORS.txt\n * Code distributed by Google as part of the polymer project is also\n * subject to an additional IP rights grant found at\n * http://polymer.github.io/PATENTS.txt\n */\n\n/**\n * The default TemplateFactory which caches Templates keyed on\n * result.type and result.strings.\n */\nfunction templateFactory(result) {\n let templateCache = templateCaches.get(result.type);\n if (templateCache === undefined) {\n templateCache = {\n stringsArray: new WeakMap(),\n keyString: new Map()\n };\n templateCaches.set(result.type, templateCache);\n }\n let template = templateCache.stringsArray.get(result.strings);\n if (template !== undefined) {\n return template;\n }\n // If the TemplateStringsArray is new, generate a key from the strings\n // This key is shared between all templates with identical content\n const key = result.strings.join(_template_js__WEBPACK_IMPORTED_MODULE_0__[\"marker\"]);\n // Check if we already have a Template for this key\n template = templateCache.keyString.get(key);\n if (template === undefined) {\n // If we have not seen this key before, create a new Template\n template = new _template_js__WEBPACK_IMPORTED_MODULE_0__[\"Template\"](result, result.getTemplateElement());\n // Cache the Template for this key\n templateCache.keyString.set(key, template);\n }\n // Cache all future queries for this TemplateStringsArray\n templateCache.stringsArray.set(result.strings, template);\n return template;\n}\nconst templateCaches = new Map();\n//# sourceMappingURL=template-factory.js.map\n\n//# sourceURL=webpack:///./node_modules/lit-html/lib/template-factory.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/lit-html/lib/template-instance.js":
|
|
/*!********************************************************!*\
|
|
!*** ./node_modules/lit-html/lib/template-instance.js ***!
|
|
\********************************************************/
|
|
/*! exports provided: TemplateInstance */
|
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"TemplateInstance\", function() { return TemplateInstance; });\n/* harmony import */ var _dom_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./dom.js */ \"./node_modules/lit-html/lib/dom.js\");\n/* harmony import */ var _template_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./template.js */ \"./node_modules/lit-html/lib/template.js\");\n/**\n * @license\n * Copyright (c) 2017 The Polymer Project Authors. All rights reserved.\n * This code may only be used under the BSD style license found at\n * http://polymer.github.io/LICENSE.txt\n * The complete set of authors may be found at\n * http://polymer.github.io/AUTHORS.txt\n * The complete set of contributors may be found at\n * http://polymer.github.io/CONTRIBUTORS.txt\n * Code distributed by Google as part of the polymer project is also\n * subject to an additional IP rights grant found at\n * http://polymer.github.io/PATENTS.txt\n */\n/**\n * @module lit-html\n */\n\n\n/**\n * An instance of a `Template` that can be attached to the DOM and updated\n * with new values.\n */\nclass TemplateInstance {\n constructor(template, processor, options) {\n this.__parts = [];\n this.template = template;\n this.processor = processor;\n this.options = options;\n }\n update(values) {\n let i = 0;\n for (const part of this.__parts) {\n if (part !== undefined) {\n part.setValue(values[i]);\n }\n i++;\n }\n for (const part of this.__parts) {\n if (part !== undefined) {\n part.commit();\n }\n }\n }\n _clone() {\n // There are a number of steps in the lifecycle of a template instance's\n // DOM fragment:\n // 1. Clone - create the instance fragment\n // 2. Adopt - adopt into the main document\n // 3. Process - find part markers and create parts\n // 4. Upgrade - upgrade custom elements\n // 5. Update - set node, attribute, property, etc., values\n // 6. Connect - connect to the document. Optional and outside of this\n // method.\n //\n // We have a few constraints on the ordering of these steps:\n // * We need to upgrade before updating, so that property values will pass\n // through any property setters.\n // * We would like to process before upgrading so that we're sure that the\n // cloned fragment is inert and not disturbed by self-modifying DOM.\n // * We want custom elements to upgrade even in disconnected fragments.\n //\n // Given these constraints, with full custom elements support we would\n // prefer the order: Clone, Process, Adopt, Upgrade, Update, Connect\n //\n // But Safari does not implement CustomElementRegistry#upgrade, so we\n // can not implement that order and still have upgrade-before-update and\n // upgrade disconnected fragments. So we instead sacrifice the\n // process-before-upgrade constraint, since in Custom Elements v1 elements\n // must not modify their light DOM in the constructor. We still have issues\n // when co-existing with CEv0 elements like Polymer 1, and with polyfills\n // that don't strictly adhere to the no-modification rule because shadow\n // DOM, which may be created in the constructor, is emulated by being placed\n // in the light DOM.\n //\n // The resulting order is on native is: Clone, Adopt, Upgrade, Process,\n // Update, Connect. document.importNode() performs Clone, Adopt, and Upgrade\n // in one step.\n //\n // The Custom Elements v1 polyfill supports upgrade(), so the order when\n // polyfilled is the more ideal: Clone, Process, Adopt, Upgrade, Update,\n // Connect.\n const fragment = _dom_js__WEBPACK_IMPORTED_MODULE_0__[\"isCEPolyfill\"] ?\n this.template.element.content.cloneNode(true) :\n document.importNode(this.template.element.content, true);\n const stack = [];\n const parts = this.template.parts;\n // Edge needs all 4 parameters present; IE11 needs 3rd parameter to be null\n const walker = document.createTreeWalker(fragment, 133 /* NodeFilter.SHOW_{ELEMENT|COMMENT|TEXT} */, null, false);\n let partIndex = 0;\n let nodeIndex = 0;\n let part;\n let node = walker.nextNode();\n // Loop through all the nodes and parts of a template\n while (partIndex < parts.length) {\n part = parts[partIndex];\n if (!Object(_template_js__WEBPACK_IMPORTED_MODULE_1__[\"isTemplatePartActive\"])(part)) {\n this.__parts.push(undefined);\n partIndex++;\n continue;\n }\n // Progress the tree walker until we find our next part's node.\n // Note that multiple parts may share the same node (attribute parts\n // on a single element), so this loop may not run at all.\n while (nodeIndex < part.index) {\n nodeIndex++;\n if (node.nodeName === 'TEMPLATE') {\n stack.push(node);\n walker.currentNode = node.content;\n }\n if ((node = walker.nextNode()) === null) {\n // We've exhausted the content inside a nested template element.\n // Because we still have parts (the outer for-loop), we know:\n // - There is a template in the stack\n // - The walker will find a nextNode outside the template\n walker.currentNode = stack.pop();\n node = walker.nextNode();\n }\n }\n // We've arrived at our part's node.\n if (part.type === 'node') {\n const part = this.processor.handleTextExpression(this.options);\n part.insertAfterNode(node.previousSibling);\n this.__parts.push(part);\n }\n else {\n this.__parts.push(...this.processor.handleAttributeExpressions(node, part.name, part.strings, this.options));\n }\n partIndex++;\n }\n if (_dom_js__WEBPACK_IMPORTED_MODULE_0__[\"isCEPolyfill\"]) {\n document.adoptNode(fragment);\n customElements.upgrade(fragment);\n }\n return fragment;\n }\n}\n//# sourceMappingURL=template-instance.js.map\n\n//# sourceURL=webpack:///./node_modules/lit-html/lib/template-instance.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/lit-html/lib/template-result.js":
|
|
/*!******************************************************!*\
|
|
!*** ./node_modules/lit-html/lib/template-result.js ***!
|
|
\******************************************************/
|
|
/*! exports provided: TemplateResult, SVGTemplateResult */
|
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"TemplateResult\", function() { return TemplateResult; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"SVGTemplateResult\", function() { return SVGTemplateResult; });\n/* harmony import */ var _dom_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./dom.js */ \"./node_modules/lit-html/lib/dom.js\");\n/* harmony import */ var _template_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./template.js */ \"./node_modules/lit-html/lib/template.js\");\n/**\n * @license\n * Copyright (c) 2017 The Polymer Project Authors. All rights reserved.\n * This code may only be used under the BSD style license found at\n * http://polymer.github.io/LICENSE.txt\n * The complete set of authors may be found at\n * http://polymer.github.io/AUTHORS.txt\n * The complete set of contributors may be found at\n * http://polymer.github.io/CONTRIBUTORS.txt\n * Code distributed by Google as part of the polymer project is also\n * subject to an additional IP rights grant found at\n * http://polymer.github.io/PATENTS.txt\n */\n/**\n * @module lit-html\n */\n\n\nconst commentMarker = ` ${_template_js__WEBPACK_IMPORTED_MODULE_1__[\"marker\"]} `;\n/**\n * The return type of `html`, which holds a Template and the values from\n * interpolated expressions.\n */\nclass TemplateResult {\n constructor(strings, values, type, processor) {\n this.strings = strings;\n this.values = values;\n this.type = type;\n this.processor = processor;\n }\n /**\n * Returns a string of HTML used to create a `<template>` element.\n */\n getHTML() {\n const l = this.strings.length - 1;\n let html = '';\n let isCommentBinding = false;\n for (let i = 0; i < l; i++) {\n const s = this.strings[i];\n // For each binding we want to determine the kind of marker to insert\n // into the template source before it's parsed by the browser's HTML\n // parser. The marker type is based on whether the expression is in an\n // attribute, text, or comment position.\n // * For node-position bindings we insert a comment with the marker\n // sentinel as its text content, like <!--{{lit-guid}}-->.\n // * For attribute bindings we insert just the marker sentinel for the\n // first binding, so that we support unquoted attribute bindings.\n // Subsequent bindings can use a comment marker because multi-binding\n // attributes must be quoted.\n // * For comment bindings we insert just the marker sentinel so we don't\n // close the comment.\n //\n // The following code scans the template source, but is *not* an HTML\n // parser. We don't need to track the tree structure of the HTML, only\n // whether a binding is inside a comment, and if not, if it appears to be\n // the first binding in an attribute.\n const commentOpen = s.lastIndexOf('<!--');\n // We're in comment position if we have a comment open with no following\n // comment close. Because <-- can appear in an attribute value there can\n // be false positives.\n isCommentBinding = (commentOpen > -1 || isCommentBinding) &&\n s.indexOf('-->', commentOpen + 1) === -1;\n // Check to see if we have an attribute-like sequence preceding the\n // expression. This can match \"name=value\" like structures in text,\n // comments, and attribute values, so there can be false-positives.\n const attributeMatch = _template_js__WEBPACK_IMPORTED_MODULE_1__[\"lastAttributeNameRegex\"].exec(s);\n if (attributeMatch === null) {\n // We're only in this branch if we don't have a attribute-like\n // preceding sequence. For comments, this guards against unusual\n // attribute values like <div foo=\"<!--${'bar'}\">. Cases like\n // <!-- foo=${'bar'}--> are handled correctly in the attribute branch\n // below.\n html += s + (isCommentBinding ? commentMarker : _template_js__WEBPACK_IMPORTED_MODULE_1__[\"nodeMarker\"]);\n }\n else {\n // For attributes we use just a marker sentinel, and also append a\n // $lit$ suffix to the name to opt-out of attribute-specific parsing\n // that IE and Edge do for style and certain SVG attributes.\n html += s.substr(0, attributeMatch.index) + attributeMatch[1] +\n attributeMatch[2] + _template_js__WEBPACK_IMPORTED_MODULE_1__[\"boundAttributeSuffix\"] + attributeMatch[3] +\n _template_js__WEBPACK_IMPORTED_MODULE_1__[\"marker\"];\n }\n }\n html += this.strings[l];\n return html;\n }\n getTemplateElement() {\n const template = document.createElement('template');\n template.innerHTML = this.getHTML();\n return template;\n }\n}\n/**\n * A TemplateResult for SVG fragments.\n *\n * This class wraps HTML in an `<svg>` tag in order to parse its contents in the\n * SVG namespace, then modifies the template to remove the `<svg>` tag so that\n * clones only container the original fragment.\n */\nclass SVGTemplateResult extends TemplateResult {\n getHTML() {\n return `<svg>${super.getHTML()}</svg>`;\n }\n getTemplateElement() {\n const template = super.getTemplateElement();\n const content = template.content;\n const svgElement = content.firstChild;\n content.removeChild(svgElement);\n Object(_dom_js__WEBPACK_IMPORTED_MODULE_0__[\"reparentNodes\"])(content, svgElement.firstChild);\n return template;\n }\n}\n//# sourceMappingURL=template-result.js.map\n\n//# sourceURL=webpack:///./node_modules/lit-html/lib/template-result.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/lit-html/lib/template.js":
|
|
/*!***********************************************!*\
|
|
!*** ./node_modules/lit-html/lib/template.js ***!
|
|
\***********************************************/
|
|
/*! exports provided: marker, nodeMarker, markerRegex, boundAttributeSuffix, Template, isTemplatePartActive, createMarker, lastAttributeNameRegex */
|
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"marker\", function() { return marker; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"nodeMarker\", function() { return nodeMarker; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"markerRegex\", function() { return markerRegex; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"boundAttributeSuffix\", function() { return boundAttributeSuffix; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"Template\", function() { return Template; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"isTemplatePartActive\", function() { return isTemplatePartActive; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"createMarker\", function() { return createMarker; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"lastAttributeNameRegex\", function() { return lastAttributeNameRegex; });\n/**\n * @license\n * Copyright (c) 2017 The Polymer Project Authors. All rights reserved.\n * This code may only be used under the BSD style license found at\n * http://polymer.github.io/LICENSE.txt\n * The complete set of authors may be found at\n * http://polymer.github.io/AUTHORS.txt\n * The complete set of contributors may be found at\n * http://polymer.github.io/CONTRIBUTORS.txt\n * Code distributed by Google as part of the polymer project is also\n * subject to an additional IP rights grant found at\n * http://polymer.github.io/PATENTS.txt\n */\n/**\n * An expression marker with embedded unique key to avoid collision with\n * possible text in templates.\n */\nconst marker = `{{lit-${String(Math.random()).slice(2)}}}`;\n/**\n * An expression marker used text-positions, multi-binding attributes, and\n * attributes with markup-like text values.\n */\nconst nodeMarker = `<!--${marker}-->`;\nconst markerRegex = new RegExp(`${marker}|${nodeMarker}`);\n/**\n * Suffix appended to all bound attribute names.\n */\nconst boundAttributeSuffix = '$lit$';\n/**\n * An updatable Template that tracks the location of dynamic parts.\n */\nclass Template {\n constructor(result, element) {\n this.parts = [];\n this.element = element;\n const nodesToRemove = [];\n const stack = [];\n // Edge needs all 4 parameters present; IE11 needs 3rd parameter to be null\n const walker = document.createTreeWalker(element.content, 133 /* NodeFilter.SHOW_{ELEMENT|COMMENT|TEXT} */, null, false);\n // Keeps track of the last index associated with a part. We try to delete\n // unnecessary nodes, but we never want to associate two different parts\n // to the same index. They must have a constant node between.\n let lastPartIndex = 0;\n let index = -1;\n let partIndex = 0;\n const { strings, values: { length } } = result;\n while (partIndex < length) {\n const node = walker.nextNode();\n if (node === null) {\n // We've exhausted the content inside a nested template element.\n // Because we still have parts (the outer for-loop), we know:\n // - There is a template in the stack\n // - The walker will find a nextNode outside the template\n walker.currentNode = stack.pop();\n continue;\n }\n index++;\n if (node.nodeType === 1 /* Node.ELEMENT_NODE */) {\n if (node.hasAttributes()) {\n const attributes = node.attributes;\n const { length } = attributes;\n // Per\n // https://developer.mozilla.org/en-US/docs/Web/API/NamedNodeMap,\n // attributes are not guaranteed to be returned in document order.\n // In particular, Edge/IE can return them out of order, so we cannot\n // assume a correspondence between part index and attribute index.\n let count = 0;\n for (let i = 0; i < length; i++) {\n if (endsWith(attributes[i].name, boundAttributeSuffix)) {\n count++;\n }\n }\n while (count-- > 0) {\n // Get the template literal section leading up to the first\n // expression in this attribute\n const stringForPart = strings[partIndex];\n // Find the attribute name\n const name = lastAttributeNameRegex.exec(stringForPart)[2];\n // Find the corresponding attribute\n // All bound attributes have had a suffix added in\n // TemplateResult#getHTML to opt out of special attribute\n // handling. To look up the attribute value we also need to add\n // the suffix.\n const attributeLookupName = name.toLowerCase() + boundAttributeSuffix;\n const attributeValue = node.getAttribute(attributeLookupName);\n node.removeAttribute(attributeLookupName);\n const statics = attributeValue.split(markerRegex);\n this.parts.push({ type: 'attribute', index, name, strings: statics });\n partIndex += statics.length - 1;\n }\n }\n if (node.tagName === 'TEMPLATE') {\n stack.push(node);\n walker.currentNode = node.content;\n }\n }\n else if (node.nodeType === 3 /* Node.TEXT_NODE */) {\n const data = node.data;\n if (data.indexOf(marker) >= 0) {\n const parent = node.parentNode;\n const strings = data.split(markerRegex);\n const lastIndex = strings.length - 1;\n // Generate a new text node for each literal section\n // These nodes are also used as the markers for node parts\n for (let i = 0; i < lastIndex; i++) {\n let insert;\n let s = strings[i];\n if (s === '') {\n insert = createMarker();\n }\n else {\n const match = lastAttributeNameRegex.exec(s);\n if (match !== null && endsWith(match[2], boundAttributeSuffix)) {\n s = s.slice(0, match.index) + match[1] +\n match[2].slice(0, -boundAttributeSuffix.length) + match[3];\n }\n insert = document.createTextNode(s);\n }\n parent.insertBefore(insert, node);\n this.parts.push({ type: 'node', index: ++index });\n }\n // If there's no text, we must insert a comment to mark our place.\n // Else, we can trust it will stick around after cloning.\n if (strings[lastIndex] === '') {\n parent.insertBefore(createMarker(), node);\n nodesToRemove.push(node);\n }\n else {\n node.data = strings[lastIndex];\n }\n // We have a part for each match found\n partIndex += lastIndex;\n }\n }\n else if (node.nodeType === 8 /* Node.COMMENT_NODE */) {\n if (node.data === marker) {\n const parent = node.parentNode;\n // Add a new marker node to be the startNode of the Part if any of\n // the following are true:\n // * We don't have a previousSibling\n // * The previousSibling is already the start of a previous part\n if (node.previousSibling === null || index === lastPartIndex) {\n index++;\n parent.insertBefore(createMarker(), node);\n }\n lastPartIndex = index;\n this.parts.push({ type: 'node', index });\n // If we don't have a nextSibling, keep this node so we have an end.\n // Else, we can remove it to save future costs.\n if (node.nextSibling === null) {\n node.data = '';\n }\n else {\n nodesToRemove.push(node);\n index--;\n }\n partIndex++;\n }\n else {\n let i = -1;\n while ((i = node.data.indexOf(marker, i + 1)) !== -1) {\n // Comment node has a binding marker inside, make an inactive part\n // The binding won't work, but subsequent bindings will\n // TODO (justinfagnani): consider whether it's even worth it to\n // make bindings in comments work\n this.parts.push({ type: 'node', index: -1 });\n partIndex++;\n }\n }\n }\n }\n // Remove text binding nodes after the walk to not disturb the TreeWalker\n for (const n of nodesToRemove) {\n n.parentNode.removeChild(n);\n }\n }\n}\nconst endsWith = (str, suffix) => {\n const index = str.length - suffix.length;\n return index >= 0 && str.slice(index) === suffix;\n};\nconst isTemplatePartActive = (part) => part.index !== -1;\n// Allows `document.createComment('')` to be renamed for a\n// small manual size-savings.\nconst createMarker = () => document.createComment('');\n/**\n * This regex extracts the attribute name preceding an attribute-position\n * expression. It does this by matching the syntax allowed for attributes\n * against the string literal directly preceding the expression, assuming that\n * the expression is in an attribute-value position.\n *\n * See attributes in the HTML spec:\n * https://www.w3.org/TR/html5/syntax.html#elements-attributes\n *\n * \" \\x09\\x0a\\x0c\\x0d\" are HTML space characters:\n * https://www.w3.org/TR/html5/infrastructure.html#space-characters\n *\n * \"\\0-\\x1F\\x7F-\\x9F\" are Unicode control characters, which includes every\n * space character except \" \".\n *\n * So an attribute is:\n * * The name: any character except a control character, space character, ('),\n * (\"), \">\", \"=\", or \"/\"\n * * Followed by zero or more space characters\n * * Followed by \"=\"\n * * Followed by zero or more space characters\n * * Followed by:\n * * Any character except space, ('), (\"), \"<\", \">\", \"=\", (`), or\n * * (\") then any non-(\"), or\n * * (') then any non-(')\n */\nconst lastAttributeNameRegex = \n// eslint-disable-next-line no-control-regex\n/([ \\x09\\x0a\\x0c\\x0d])([^\\0-\\x1F\\x7F-\\x9F \"'>=/]+)([ \\x09\\x0a\\x0c\\x0d]*=[ \\x09\\x0a\\x0c\\x0d]*(?:[^ \\x09\\x0a\\x0c\\x0d\"'`<>=]*|\"[^\"]*|'[^']*))$/;\n//# sourceMappingURL=template.js.map\n\n//# sourceURL=webpack:///./node_modules/lit-html/lib/template.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/lit-html/lit-html.js":
|
|
/*!*******************************************!*\
|
|
!*** ./node_modules/lit-html/lit-html.js ***!
|
|
\*******************************************/
|
|
/*! exports provided: DefaultTemplateProcessor, defaultTemplateProcessor, directive, isDirective, removeNodes, reparentNodes, noChange, nothing, AttributeCommitter, AttributePart, BooleanAttributePart, EventPart, isIterable, isPrimitive, NodePart, PropertyCommitter, PropertyPart, parts, render, templateCaches, templateFactory, TemplateInstance, SVGTemplateResult, TemplateResult, createMarker, isTemplatePartActive, Template, html, svg */
|
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"html\", function() { return html; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"svg\", function() { return svg; });\n/* harmony import */ var _lib_default_template_processor_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./lib/default-template-processor.js */ \"./node_modules/lit-html/lib/default-template-processor.js\");\n/* harmony import */ var _lib_template_result_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./lib/template-result.js */ \"./node_modules/lit-html/lib/template-result.js\");\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"DefaultTemplateProcessor\", function() { return _lib_default_template_processor_js__WEBPACK_IMPORTED_MODULE_0__[\"DefaultTemplateProcessor\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"defaultTemplateProcessor\", function() { return _lib_default_template_processor_js__WEBPACK_IMPORTED_MODULE_0__[\"defaultTemplateProcessor\"]; });\n\n/* harmony import */ var _lib_directive_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./lib/directive.js */ \"./node_modules/lit-html/lib/directive.js\");\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"directive\", function() { return _lib_directive_js__WEBPACK_IMPORTED_MODULE_2__[\"directive\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"isDirective\", function() { return _lib_directive_js__WEBPACK_IMPORTED_MODULE_2__[\"isDirective\"]; });\n\n/* harmony import */ var _lib_dom_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./lib/dom.js */ \"./node_modules/lit-html/lib/dom.js\");\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"removeNodes\", function() { return _lib_dom_js__WEBPACK_IMPORTED_MODULE_3__[\"removeNodes\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"reparentNodes\", function() { return _lib_dom_js__WEBPACK_IMPORTED_MODULE_3__[\"reparentNodes\"]; });\n\n/* harmony import */ var _lib_part_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./lib/part.js */ \"./node_modules/lit-html/lib/part.js\");\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"noChange\", function() { return _lib_part_js__WEBPACK_IMPORTED_MODULE_4__[\"noChange\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"nothing\", function() { return _lib_part_js__WEBPACK_IMPORTED_MODULE_4__[\"nothing\"]; });\n\n/* harmony import */ var _lib_parts_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./lib/parts.js */ \"./node_modules/lit-html/lib/parts.js\");\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"AttributeCommitter\", function() { return _lib_parts_js__WEBPACK_IMPORTED_MODULE_5__[\"AttributeCommitter\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"AttributePart\", function() { return _lib_parts_js__WEBPACK_IMPORTED_MODULE_5__[\"AttributePart\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"BooleanAttributePart\", function() { return _lib_parts_js__WEBPACK_IMPORTED_MODULE_5__[\"BooleanAttributePart\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"EventPart\", function() { return _lib_parts_js__WEBPACK_IMPORTED_MODULE_5__[\"EventPart\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"isIterable\", function() { return _lib_parts_js__WEBPACK_IMPORTED_MODULE_5__[\"isIterable\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"isPrimitive\", function() { return _lib_parts_js__WEBPACK_IMPORTED_MODULE_5__[\"isPrimitive\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"NodePart\", function() { return _lib_parts_js__WEBPACK_IMPORTED_MODULE_5__[\"NodePart\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"PropertyCommitter\", function() { return _lib_parts_js__WEBPACK_IMPORTED_MODULE_5__[\"PropertyCommitter\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"PropertyPart\", function() { return _lib_parts_js__WEBPACK_IMPORTED_MODULE_5__[\"PropertyPart\"]; });\n\n/* harmony import */ var _lib_render_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./lib/render.js */ \"./node_modules/lit-html/lib/render.js\");\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"parts\", function() { return _lib_render_js__WEBPACK_IMPORTED_MODULE_6__[\"parts\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"render\", function() { return _lib_render_js__WEBPACK_IMPORTED_MODULE_6__[\"render\"]; });\n\n/* harmony import */ var _lib_template_factory_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./lib/template-factory.js */ \"./node_modules/lit-html/lib/template-factory.js\");\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"templateCaches\", function() { return _lib_template_factory_js__WEBPACK_IMPORTED_MODULE_7__[\"templateCaches\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"templateFactory\", function() { return _lib_template_factory_js__WEBPACK_IMPORTED_MODULE_7__[\"templateFactory\"]; });\n\n/* harmony import */ var _lib_template_instance_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ./lib/template-instance.js */ \"./node_modules/lit-html/lib/template-instance.js\");\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"TemplateInstance\", function() { return _lib_template_instance_js__WEBPACK_IMPORTED_MODULE_8__[\"TemplateInstance\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"SVGTemplateResult\", function() { return _lib_template_result_js__WEBPACK_IMPORTED_MODULE_1__[\"SVGTemplateResult\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"TemplateResult\", function() { return _lib_template_result_js__WEBPACK_IMPORTED_MODULE_1__[\"TemplateResult\"]; });\n\n/* harmony import */ var _lib_template_js__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ./lib/template.js */ \"./node_modules/lit-html/lib/template.js\");\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"createMarker\", function() { return _lib_template_js__WEBPACK_IMPORTED_MODULE_9__[\"createMarker\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"isTemplatePartActive\", function() { return _lib_template_js__WEBPACK_IMPORTED_MODULE_9__[\"isTemplatePartActive\"]; });\n\n/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, \"Template\", function() { return _lib_template_js__WEBPACK_IMPORTED_MODULE_9__[\"Template\"]; });\n\n/**\n * @license\n * Copyright (c) 2017 The Polymer Project Authors. All rights reserved.\n * This code may only be used under the BSD style license found at\n * http://polymer.github.io/LICENSE.txt\n * The complete set of authors may be found at\n * http://polymer.github.io/AUTHORS.txt\n * The complete set of contributors may be found at\n * http://polymer.github.io/CONTRIBUTORS.txt\n * Code distributed by Google as part of the polymer project is also\n * subject to an additional IP rights grant found at\n * http://polymer.github.io/PATENTS.txt\n */\n/**\n *\n * Main lit-html module.\n *\n * Main exports:\n *\n * - [[html]]\n * - [[svg]]\n * - [[render]]\n *\n * @module lit-html\n * @preferred\n */\n/**\n * Do not remove this comment; it keeps typedoc from misplacing the module\n * docs.\n */\n\n\n\n\n// TODO(justinfagnani): remove line when we get NodePart moving methods\n\n\n\n\n\n\n\n\n// IMPORTANT: do not change the property name or the assignment expression.\n// This line will be used in regexes to search for lit-html usage.\n// TODO(justinfagnani): inject version number at build time\nif (typeof window !== 'undefined') {\n (window['litHtmlVersions'] || (window['litHtmlVersions'] = [])).push('1.2.1');\n}\n/**\n * Interprets a template literal as an HTML template that can efficiently\n * render to and update a container.\n */\nconst html = (strings, ...values) => new _lib_template_result_js__WEBPACK_IMPORTED_MODULE_1__[\"TemplateResult\"](strings, values, 'html', _lib_default_template_processor_js__WEBPACK_IMPORTED_MODULE_0__[\"defaultTemplateProcessor\"]);\n/**\n * Interprets a template literal as an SVG template that can efficiently\n * render to and update a container.\n */\nconst svg = (strings, ...values) => new _lib_template_result_js__WEBPACK_IMPORTED_MODULE_1__[\"SVGTemplateResult\"](strings, values, 'svg', _lib_default_template_processor_js__WEBPACK_IMPORTED_MODULE_0__[\"defaultTemplateProcessor\"]);\n//# sourceMappingURL=lit-html.js.map\n\n//# sourceURL=webpack:///./node_modules/lit-html/lit-html.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/object-inspect/index.js":
|
|
/*!**********************************************!*\
|
|
!*** ./node_modules/object-inspect/index.js ***!
|
|
\**********************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
eval("var hasMap = typeof Map === 'function' && Map.prototype;\nvar mapSizeDescriptor = Object.getOwnPropertyDescriptor && hasMap ? Object.getOwnPropertyDescriptor(Map.prototype, 'size') : null;\nvar mapSize = hasMap && mapSizeDescriptor && typeof mapSizeDescriptor.get === 'function' ? mapSizeDescriptor.get : null;\nvar mapForEach = hasMap && Map.prototype.forEach;\nvar hasSet = typeof Set === 'function' && Set.prototype;\nvar setSizeDescriptor = Object.getOwnPropertyDescriptor && hasSet ? Object.getOwnPropertyDescriptor(Set.prototype, 'size') : null;\nvar setSize = hasSet && setSizeDescriptor && typeof setSizeDescriptor.get === 'function' ? setSizeDescriptor.get : null;\nvar setForEach = hasSet && Set.prototype.forEach;\nvar hasWeakMap = typeof WeakMap === 'function' && WeakMap.prototype;\nvar weakMapHas = hasWeakMap ? WeakMap.prototype.has : null;\nvar hasWeakSet = typeof WeakSet === 'function' && WeakSet.prototype;\nvar weakSetHas = hasWeakSet ? WeakSet.prototype.has : null;\nvar booleanValueOf = Boolean.prototype.valueOf;\nvar objectToString = Object.prototype.toString;\nvar functionToString = Function.prototype.toString;\nvar match = String.prototype.match;\nvar bigIntValueOf = typeof BigInt === 'function' ? BigInt.prototype.valueOf : null;\n\nvar inspectCustom = __webpack_require__(/*! ./util.inspect */ 0).custom;\nvar inspectSymbol = inspectCustom && isSymbol(inspectCustom) ? inspectCustom : null;\n\nmodule.exports = function inspect_(obj, options, depth, seen) {\n var opts = options || {};\n\n if (has(opts, 'quoteStyle') && (opts.quoteStyle !== 'single' && opts.quoteStyle !== 'double')) {\n throw new TypeError('option \"quoteStyle\" must be \"single\" or \"double\"');\n }\n if (\n has(opts, 'maxStringLength') && (typeof opts.maxStringLength === 'number'\n ? opts.maxStringLength < 0 && opts.maxStringLength !== Infinity\n : opts.maxStringLength !== null\n )\n ) {\n throw new TypeError('option \"maxStringLength\", if provided, must be a positive integer, Infinity, or `null`');\n }\n var customInspect = has(opts, 'customInspect') ? opts.customInspect : true;\n if (typeof customInspect !== 'boolean') {\n throw new TypeError('option \"customInspect\", if provided, must be `true` or `false`');\n }\n\n if (\n has(opts, 'indent')\n && opts.indent !== null\n && opts.indent !== '\\t'\n && !(parseInt(opts.indent, 10) === opts.indent && opts.indent > 0)\n ) {\n throw new TypeError('options \"indent\" must be \"\\\\t\", an integer > 0, or `null`');\n }\n\n if (typeof obj === 'undefined') {\n return 'undefined';\n }\n if (obj === null) {\n return 'null';\n }\n if (typeof obj === 'boolean') {\n return obj ? 'true' : 'false';\n }\n\n if (typeof obj === 'string') {\n return inspectString(obj, opts);\n }\n if (typeof obj === 'number') {\n if (obj === 0) {\n return Infinity / obj > 0 ? '0' : '-0';\n }\n return String(obj);\n }\n if (typeof obj === 'bigint') { // eslint-disable-line valid-typeof\n return String(obj) + 'n';\n }\n\n var maxDepth = typeof opts.depth === 'undefined' ? 5 : opts.depth;\n if (typeof depth === 'undefined') { depth = 0; }\n if (depth >= maxDepth && maxDepth > 0 && typeof obj === 'object') {\n return isArray(obj) ? '[Array]' : '[Object]';\n }\n\n var indent = getIndent(opts, depth);\n\n if (typeof seen === 'undefined') {\n seen = [];\n } else if (indexOf(seen, obj) >= 0) {\n return '[Circular]';\n }\n\n function inspect(value, from, noIndent) {\n if (from) {\n seen = seen.slice();\n seen.push(from);\n }\n if (noIndent) {\n var newOpts = {\n depth: opts.depth\n };\n if (has(opts, 'quoteStyle')) {\n newOpts.quoteStyle = opts.quoteStyle;\n }\n return inspect_(value, newOpts, depth + 1, seen);\n }\n return inspect_(value, opts, depth + 1, seen);\n }\n\n if (typeof obj === 'function') {\n var name = nameOf(obj);\n return '[Function' + (name ? ': ' + name : ' (anonymous)') + ']';\n }\n if (isSymbol(obj)) {\n var symString = Symbol.prototype.toString.call(obj);\n return typeof obj === 'object' ? markBoxed(symString) : symString;\n }\n if (isElement(obj)) {\n var s = '<' + String(obj.nodeName).toLowerCase();\n var attrs = obj.attributes || [];\n for (var i = 0; i < attrs.length; i++) {\n s += ' ' + attrs[i].name + '=' + wrapQuotes(quote(attrs[i].value), 'double', opts);\n }\n s += '>';\n if (obj.childNodes && obj.childNodes.length) { s += '...'; }\n s += '</' + String(obj.nodeName).toLowerCase() + '>';\n return s;\n }\n if (isArray(obj)) {\n if (obj.length === 0) { return '[]'; }\n var xs = arrObjKeys(obj, inspect);\n if (indent && !singleLineValues(xs)) {\n return '[' + indentedJoin(xs, indent) + ']';\n }\n return '[ ' + xs.join(', ') + ' ]';\n }\n if (isError(obj)) {\n var parts = arrObjKeys(obj, inspect);\n if (parts.length === 0) { return '[' + String(obj) + ']'; }\n return '{ [' + String(obj) + '] ' + parts.join(', ') + ' }';\n }\n if (typeof obj === 'object' && customInspect) {\n if (inspectSymbol && typeof obj[inspectSymbol] === 'function') {\n return obj[inspectSymbol]();\n } else if (typeof obj.inspect === 'function') {\n return obj.inspect();\n }\n }\n if (isMap(obj)) {\n var mapParts = [];\n mapForEach.call(obj, function (value, key) {\n mapParts.push(inspect(key, obj, true) + ' => ' + inspect(value, obj));\n });\n return collectionOf('Map', mapSize.call(obj), mapParts, indent);\n }\n if (isSet(obj)) {\n var setParts = [];\n setForEach.call(obj, function (value) {\n setParts.push(inspect(value, obj));\n });\n return collectionOf('Set', setSize.call(obj), setParts, indent);\n }\n if (isWeakMap(obj)) {\n return weakCollectionOf('WeakMap');\n }\n if (isWeakSet(obj)) {\n return weakCollectionOf('WeakSet');\n }\n if (isNumber(obj)) {\n return markBoxed(inspect(Number(obj)));\n }\n if (isBigInt(obj)) {\n return markBoxed(inspect(bigIntValueOf.call(obj)));\n }\n if (isBoolean(obj)) {\n return markBoxed(booleanValueOf.call(obj));\n }\n if (isString(obj)) {\n return markBoxed(inspect(String(obj)));\n }\n if (!isDate(obj) && !isRegExp(obj)) {\n var ys = arrObjKeys(obj, inspect);\n if (ys.length === 0) { return '{}'; }\n if (indent) {\n return '{' + indentedJoin(ys, indent) + '}';\n }\n return '{ ' + ys.join(', ') + ' }';\n }\n return String(obj);\n};\n\nfunction wrapQuotes(s, defaultStyle, opts) {\n var quoteChar = (opts.quoteStyle || defaultStyle) === 'double' ? '\"' : \"'\";\n return quoteChar + s + quoteChar;\n}\n\nfunction quote(s) {\n return String(s).replace(/\"/g, '"');\n}\n\nfunction isArray(obj) { return toStr(obj) === '[object Array]'; }\nfunction isDate(obj) { return toStr(obj) === '[object Date]'; }\nfunction isRegExp(obj) { return toStr(obj) === '[object RegExp]'; }\nfunction isError(obj) { return toStr(obj) === '[object Error]'; }\nfunction isSymbol(obj) { return toStr(obj) === '[object Symbol]'; }\nfunction isString(obj) { return toStr(obj) === '[object String]'; }\nfunction isNumber(obj) { return toStr(obj) === '[object Number]'; }\nfunction isBigInt(obj) { return toStr(obj) === '[object BigInt]'; }\nfunction isBoolean(obj) { return toStr(obj) === '[object Boolean]'; }\n\nvar hasOwn = Object.prototype.hasOwnProperty || function (key) { return key in this; };\nfunction has(obj, key) {\n return hasOwn.call(obj, key);\n}\n\nfunction toStr(obj) {\n return objectToString.call(obj);\n}\n\nfunction nameOf(f) {\n if (f.name) { return f.name; }\n var m = match.call(functionToString.call(f), /^function\\s*([\\w$]+)/);\n if (m) { return m[1]; }\n return null;\n}\n\nfunction indexOf(xs, x) {\n if (xs.indexOf) { return xs.indexOf(x); }\n for (var i = 0, l = xs.length; i < l; i++) {\n if (xs[i] === x) { return i; }\n }\n return -1;\n}\n\nfunction isMap(x) {\n if (!mapSize || !x || typeof x !== 'object') {\n return false;\n }\n try {\n mapSize.call(x);\n try {\n setSize.call(x);\n } catch (s) {\n return true;\n }\n return x instanceof Map; // core-js workaround, pre-v2.5.0\n } catch (e) {}\n return false;\n}\n\nfunction isWeakMap(x) {\n if (!weakMapHas || !x || typeof x !== 'object') {\n return false;\n }\n try {\n weakMapHas.call(x, weakMapHas);\n try {\n weakSetHas.call(x, weakSetHas);\n } catch (s) {\n return true;\n }\n return x instanceof WeakMap; // core-js workaround, pre-v2.5.0\n } catch (e) {}\n return false;\n}\n\nfunction isSet(x) {\n if (!setSize || !x || typeof x !== 'object') {\n return false;\n }\n try {\n setSize.call(x);\n try {\n mapSize.call(x);\n } catch (m) {\n return true;\n }\n return x instanceof Set; // core-js workaround, pre-v2.5.0\n } catch (e) {}\n return false;\n}\n\nfunction isWeakSet(x) {\n if (!weakSetHas || !x || typeof x !== 'object') {\n return false;\n }\n try {\n weakSetHas.call(x, weakSetHas);\n try {\n weakMapHas.call(x, weakMapHas);\n } catch (s) {\n return true;\n }\n return x instanceof WeakSet; // core-js workaround, pre-v2.5.0\n } catch (e) {}\n return false;\n}\n\nfunction isElement(x) {\n if (!x || typeof x !== 'object') { return false; }\n if (typeof HTMLElement !== 'undefined' && x instanceof HTMLElement) {\n return true;\n }\n return typeof x.nodeName === 'string' && typeof x.getAttribute === 'function';\n}\n\nfunction inspectString(str, opts) {\n if (str.length > opts.maxStringLength) {\n var remaining = str.length - opts.maxStringLength;\n var trailer = '... ' + remaining + ' more character' + (remaining > 1 ? 's' : '');\n return inspectString(str.slice(0, opts.maxStringLength), opts) + trailer;\n }\n // eslint-disable-next-line no-control-regex\n var s = str.replace(/(['\\\\])/g, '\\\\$1').replace(/[\\x00-\\x1f]/g, lowbyte);\n return wrapQuotes(s, 'single', opts);\n}\n\nfunction lowbyte(c) {\n var n = c.charCodeAt(0);\n var x = {\n 8: 'b', 9: 't', 10: 'n', 12: 'f', 13: 'r'\n }[n];\n if (x) { return '\\\\' + x; }\n return '\\\\x' + (n < 0x10 ? '0' : '') + n.toString(16);\n}\n\nfunction markBoxed(str) {\n return 'Object(' + str + ')';\n}\n\nfunction weakCollectionOf(type) {\n return type + ' { ? }';\n}\n\nfunction collectionOf(type, size, entries, indent) {\n var joinedEntries = indent ? indentedJoin(entries, indent) : entries.join(', ');\n return type + ' (' + size + ') {' + joinedEntries + '}';\n}\n\nfunction singleLineValues(xs) {\n for (var i = 0; i < xs.length; i++) {\n if (indexOf(xs[i], '\\n') >= 0) {\n return false;\n }\n }\n return true;\n}\n\nfunction getIndent(opts, depth) {\n var baseIndent;\n if (opts.indent === '\\t') {\n baseIndent = '\\t';\n } else if (typeof opts.indent === 'number' && opts.indent > 0) {\n baseIndent = Array(opts.indent + 1).join(' ');\n } else {\n return null;\n }\n return {\n base: baseIndent,\n prev: Array(depth + 1).join(baseIndent)\n };\n}\n\nfunction indentedJoin(xs, indent) {\n if (xs.length === 0) { return ''; }\n var lineJoiner = '\\n' + indent.prev + indent.base;\n return lineJoiner + xs.join(',' + lineJoiner) + '\\n' + indent.prev;\n}\n\nfunction arrObjKeys(obj, inspect) {\n var isArr = isArray(obj);\n var xs = [];\n if (isArr) {\n xs.length = obj.length;\n for (var i = 0; i < obj.length; i++) {\n xs[i] = has(obj, i) ? inspect(obj[i], obj) : '';\n }\n }\n for (var key in obj) { // eslint-disable-line no-restricted-syntax\n if (!has(obj, key)) { continue; } // eslint-disable-line no-restricted-syntax, no-continue\n if (isArr && String(Number(key)) === key && key < obj.length) { continue; } // eslint-disable-line no-restricted-syntax, no-continue\n if ((/[^\\w$]/).test(key)) {\n xs.push(inspect(key, obj) + ': ' + inspect(obj[key], obj));\n } else {\n xs.push(key + ': ' + inspect(obj[key], obj));\n }\n }\n return xs;\n}\n\n\n//# sourceURL=webpack:///./node_modules/object-inspect/index.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/object-is/implementation.js":
|
|
/*!**************************************************!*\
|
|
!*** ./node_modules/object-is/implementation.js ***!
|
|
\**************************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\nvar numberIsNaN = function (value) {\n\treturn value !== value;\n};\n\nmodule.exports = function is(a, b) {\n\tif (a === 0 && b === 0) {\n\t\treturn 1 / a === 1 / b;\n\t}\n\tif (a === b) {\n\t\treturn true;\n\t}\n\tif (numberIsNaN(a) && numberIsNaN(b)) {\n\t\treturn true;\n\t}\n\treturn false;\n};\n\n\n\n//# sourceURL=webpack:///./node_modules/object-is/implementation.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/object-is/index.js":
|
|
/*!*****************************************!*\
|
|
!*** ./node_modules/object-is/index.js ***!
|
|
\*****************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\nvar define = __webpack_require__(/*! define-properties */ \"./node_modules/define-properties/index.js\");\nvar callBind = __webpack_require__(/*! es-abstract/helpers/callBind */ \"./node_modules/es-abstract/helpers/callBind.js\");\n\nvar implementation = __webpack_require__(/*! ./implementation */ \"./node_modules/object-is/implementation.js\");\nvar getPolyfill = __webpack_require__(/*! ./polyfill */ \"./node_modules/object-is/polyfill.js\");\nvar shim = __webpack_require__(/*! ./shim */ \"./node_modules/object-is/shim.js\");\n\nvar polyfill = callBind(getPolyfill(), Object);\n\ndefine(polyfill, {\n\tgetPolyfill: getPolyfill,\n\timplementation: implementation,\n\tshim: shim\n});\n\nmodule.exports = polyfill;\n\n\n//# sourceURL=webpack:///./node_modules/object-is/index.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/object-is/polyfill.js":
|
|
/*!********************************************!*\
|
|
!*** ./node_modules/object-is/polyfill.js ***!
|
|
\********************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\nvar implementation = __webpack_require__(/*! ./implementation */ \"./node_modules/object-is/implementation.js\");\n\nmodule.exports = function getPolyfill() {\n\treturn typeof Object.is === 'function' ? Object.is : implementation;\n};\n\n\n//# sourceURL=webpack:///./node_modules/object-is/polyfill.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/object-is/shim.js":
|
|
/*!****************************************!*\
|
|
!*** ./node_modules/object-is/shim.js ***!
|
|
\****************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\nvar getPolyfill = __webpack_require__(/*! ./polyfill */ \"./node_modules/object-is/polyfill.js\");\nvar define = __webpack_require__(/*! define-properties */ \"./node_modules/define-properties/index.js\");\n\nmodule.exports = function shimObjectIs() {\n\tvar polyfill = getPolyfill();\n\tdefine(Object, { is: polyfill }, {\n\t\tis: function testObjectIs() {\n\t\t\treturn Object.is !== polyfill;\n\t\t}\n\t});\n\treturn polyfill;\n};\n\n\n//# sourceURL=webpack:///./node_modules/object-is/shim.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/object-keys/implementation.js":
|
|
/*!****************************************************!*\
|
|
!*** ./node_modules/object-keys/implementation.js ***!
|
|
\****************************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\nvar keysShim;\nif (!Object.keys) {\n\t// modified from https://github.com/es-shims/es5-shim\n\tvar has = Object.prototype.hasOwnProperty;\n\tvar toStr = Object.prototype.toString;\n\tvar isArgs = __webpack_require__(/*! ./isArguments */ \"./node_modules/object-keys/isArguments.js\"); // eslint-disable-line global-require\n\tvar isEnumerable = Object.prototype.propertyIsEnumerable;\n\tvar hasDontEnumBug = !isEnumerable.call({ toString: null }, 'toString');\n\tvar hasProtoEnumBug = isEnumerable.call(function () {}, 'prototype');\n\tvar dontEnums = [\n\t\t'toString',\n\t\t'toLocaleString',\n\t\t'valueOf',\n\t\t'hasOwnProperty',\n\t\t'isPrototypeOf',\n\t\t'propertyIsEnumerable',\n\t\t'constructor'\n\t];\n\tvar equalsConstructorPrototype = function (o) {\n\t\tvar ctor = o.constructor;\n\t\treturn ctor && ctor.prototype === o;\n\t};\n\tvar excludedKeys = {\n\t\t$applicationCache: true,\n\t\t$console: true,\n\t\t$external: true,\n\t\t$frame: true,\n\t\t$frameElement: true,\n\t\t$frames: true,\n\t\t$innerHeight: true,\n\t\t$innerWidth: true,\n\t\t$onmozfullscreenchange: true,\n\t\t$onmozfullscreenerror: true,\n\t\t$outerHeight: true,\n\t\t$outerWidth: true,\n\t\t$pageXOffset: true,\n\t\t$pageYOffset: true,\n\t\t$parent: true,\n\t\t$scrollLeft: true,\n\t\t$scrollTop: true,\n\t\t$scrollX: true,\n\t\t$scrollY: true,\n\t\t$self: true,\n\t\t$webkitIndexedDB: true,\n\t\t$webkitStorageInfo: true,\n\t\t$window: true\n\t};\n\tvar hasAutomationEqualityBug = (function () {\n\t\t/* global window */\n\t\tif (typeof window === 'undefined') { return false; }\n\t\tfor (var k in window) {\n\t\t\ttry {\n\t\t\t\tif (!excludedKeys['$' + k] && has.call(window, k) && window[k] !== null && typeof window[k] === 'object') {\n\t\t\t\t\ttry {\n\t\t\t\t\t\tequalsConstructorPrototype(window[k]);\n\t\t\t\t\t} catch (e) {\n\t\t\t\t\t\treturn true;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t} catch (e) {\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\t\treturn false;\n\t}());\n\tvar equalsConstructorPrototypeIfNotBuggy = function (o) {\n\t\t/* global window */\n\t\tif (typeof window === 'undefined' || !hasAutomationEqualityBug) {\n\t\t\treturn equalsConstructorPrototype(o);\n\t\t}\n\t\ttry {\n\t\t\treturn equalsConstructorPrototype(o);\n\t\t} catch (e) {\n\t\t\treturn false;\n\t\t}\n\t};\n\n\tkeysShim = function keys(object) {\n\t\tvar isObject = object !== null && typeof object === 'object';\n\t\tvar isFunction = toStr.call(object) === '[object Function]';\n\t\tvar isArguments = isArgs(object);\n\t\tvar isString = isObject && toStr.call(object) === '[object String]';\n\t\tvar theKeys = [];\n\n\t\tif (!isObject && !isFunction && !isArguments) {\n\t\t\tthrow new TypeError('Object.keys called on a non-object');\n\t\t}\n\n\t\tvar skipProto = hasProtoEnumBug && isFunction;\n\t\tif (isString && object.length > 0 && !has.call(object, 0)) {\n\t\t\tfor (var i = 0; i < object.length; ++i) {\n\t\t\t\ttheKeys.push(String(i));\n\t\t\t}\n\t\t}\n\n\t\tif (isArguments && object.length > 0) {\n\t\t\tfor (var j = 0; j < object.length; ++j) {\n\t\t\t\ttheKeys.push(String(j));\n\t\t\t}\n\t\t} else {\n\t\t\tfor (var name in object) {\n\t\t\t\tif (!(skipProto && name === 'prototype') && has.call(object, name)) {\n\t\t\t\t\ttheKeys.push(String(name));\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tif (hasDontEnumBug) {\n\t\t\tvar skipConstructor = equalsConstructorPrototypeIfNotBuggy(object);\n\n\t\t\tfor (var k = 0; k < dontEnums.length; ++k) {\n\t\t\t\tif (!(skipConstructor && dontEnums[k] === 'constructor') && has.call(object, dontEnums[k])) {\n\t\t\t\t\ttheKeys.push(dontEnums[k]);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn theKeys;\n\t};\n}\nmodule.exports = keysShim;\n\n\n//# sourceURL=webpack:///./node_modules/object-keys/implementation.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/object-keys/index.js":
|
|
/*!*******************************************!*\
|
|
!*** ./node_modules/object-keys/index.js ***!
|
|
\*******************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\nvar slice = Array.prototype.slice;\nvar isArgs = __webpack_require__(/*! ./isArguments */ \"./node_modules/object-keys/isArguments.js\");\n\nvar origKeys = Object.keys;\nvar keysShim = origKeys ? function keys(o) { return origKeys(o); } : __webpack_require__(/*! ./implementation */ \"./node_modules/object-keys/implementation.js\");\n\nvar originalKeys = Object.keys;\n\nkeysShim.shim = function shimObjectKeys() {\n\tif (Object.keys) {\n\t\tvar keysWorksWithArguments = (function () {\n\t\t\t// Safari 5.0 bug\n\t\t\tvar args = Object.keys(arguments);\n\t\t\treturn args && args.length === arguments.length;\n\t\t}(1, 2));\n\t\tif (!keysWorksWithArguments) {\n\t\t\tObject.keys = function keys(object) { // eslint-disable-line func-name-matching\n\t\t\t\tif (isArgs(object)) {\n\t\t\t\t\treturn originalKeys(slice.call(object));\n\t\t\t\t}\n\t\t\t\treturn originalKeys(object);\n\t\t\t};\n\t\t}\n\t} else {\n\t\tObject.keys = keysShim;\n\t}\n\treturn Object.keys || keysShim;\n};\n\nmodule.exports = keysShim;\n\n\n//# sourceURL=webpack:///./node_modules/object-keys/index.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/object-keys/isArguments.js":
|
|
/*!*************************************************!*\
|
|
!*** ./node_modules/object-keys/isArguments.js ***!
|
|
\*************************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\nvar toStr = Object.prototype.toString;\n\nmodule.exports = function isArguments(value) {\n\tvar str = toStr.call(value);\n\tvar isArgs = str === '[object Arguments]';\n\tif (!isArgs) {\n\t\tisArgs = str !== '[object Array]' &&\n\t\t\tvalue !== null &&\n\t\t\ttypeof value === 'object' &&\n\t\t\ttypeof value.length === 'number' &&\n\t\t\tvalue.length >= 0 &&\n\t\t\ttoStr.call(value.callee) === '[object Function]';\n\t}\n\treturn isArgs;\n};\n\n\n//# sourceURL=webpack:///./node_modules/object-keys/isArguments.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/object.assign/implementation.js":
|
|
/*!******************************************************!*\
|
|
!*** ./node_modules/object.assign/implementation.js ***!
|
|
\******************************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\n// modified from https://github.com/es-shims/es6-shim\nvar keys = __webpack_require__(/*! object-keys */ \"./node_modules/object-keys/index.js\");\nvar bind = __webpack_require__(/*! function-bind */ \"./node_modules/function-bind/index.js\");\nvar canBeObject = function (obj) {\n\treturn typeof obj !== 'undefined' && obj !== null;\n};\nvar hasSymbols = __webpack_require__(/*! has-symbols/shams */ \"./node_modules/has-symbols/shams.js\")();\nvar toObject = Object;\nvar push = bind.call(Function.call, Array.prototype.push);\nvar propIsEnumerable = bind.call(Function.call, Object.prototype.propertyIsEnumerable);\nvar originalGetSymbols = hasSymbols ? Object.getOwnPropertySymbols : null;\n\nmodule.exports = function assign(target, source1) {\n\tif (!canBeObject(target)) { throw new TypeError('target must be an object'); }\n\tvar objTarget = toObject(target);\n\tvar s, source, i, props, syms, value, key;\n\tfor (s = 1; s < arguments.length; ++s) {\n\t\tsource = toObject(arguments[s]);\n\t\tprops = keys(source);\n\t\tvar getSymbols = hasSymbols && (Object.getOwnPropertySymbols || originalGetSymbols);\n\t\tif (getSymbols) {\n\t\t\tsyms = getSymbols(source);\n\t\t\tfor (i = 0; i < syms.length; ++i) {\n\t\t\t\tkey = syms[i];\n\t\t\t\tif (propIsEnumerable(source, key)) {\n\t\t\t\t\tpush(props, key);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tfor (i = 0; i < props.length; ++i) {\n\t\t\tkey = props[i];\n\t\t\tvalue = source[key];\n\t\t\tif (propIsEnumerable(source, key)) {\n\t\t\t\tobjTarget[key] = value;\n\t\t\t}\n\t\t}\n\t}\n\treturn objTarget;\n};\n\n\n//# sourceURL=webpack:///./node_modules/object.assign/implementation.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/object.assign/index.js":
|
|
/*!*********************************************!*\
|
|
!*** ./node_modules/object.assign/index.js ***!
|
|
\*********************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\nvar defineProperties = __webpack_require__(/*! define-properties */ \"./node_modules/define-properties/index.js\");\n\nvar implementation = __webpack_require__(/*! ./implementation */ \"./node_modules/object.assign/implementation.js\");\nvar getPolyfill = __webpack_require__(/*! ./polyfill */ \"./node_modules/object.assign/polyfill.js\");\nvar shim = __webpack_require__(/*! ./shim */ \"./node_modules/object.assign/shim.js\");\n\nvar polyfill = getPolyfill();\n\ndefineProperties(polyfill, {\n\tgetPolyfill: getPolyfill,\n\timplementation: implementation,\n\tshim: shim\n});\n\nmodule.exports = polyfill;\n\n\n//# sourceURL=webpack:///./node_modules/object.assign/index.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/object.assign/polyfill.js":
|
|
/*!************************************************!*\
|
|
!*** ./node_modules/object.assign/polyfill.js ***!
|
|
\************************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\nvar implementation = __webpack_require__(/*! ./implementation */ \"./node_modules/object.assign/implementation.js\");\n\nvar lacksProperEnumerationOrder = function () {\n\tif (!Object.assign) {\n\t\treturn false;\n\t}\n\t// v8, specifically in node 4.x, has a bug with incorrect property enumeration order\n\t// note: this does not detect the bug unless there's 20 characters\n\tvar str = 'abcdefghijklmnopqrst';\n\tvar letters = str.split('');\n\tvar map = {};\n\tfor (var i = 0; i < letters.length; ++i) {\n\t\tmap[letters[i]] = letters[i];\n\t}\n\tvar obj = Object.assign({}, map);\n\tvar actual = '';\n\tfor (var k in obj) {\n\t\tactual += k;\n\t}\n\treturn str !== actual;\n};\n\nvar assignHasPendingExceptions = function () {\n\tif (!Object.assign || !Object.preventExtensions) {\n\t\treturn false;\n\t}\n\t// Firefox 37 still has \"pending exception\" logic in its Object.assign implementation,\n\t// which is 72% slower than our shim, and Firefox 40's native implementation.\n\tvar thrower = Object.preventExtensions({ 1: 2 });\n\ttry {\n\t\tObject.assign(thrower, 'xy');\n\t} catch (e) {\n\t\treturn thrower[1] === 'y';\n\t}\n\treturn false;\n};\n\nmodule.exports = function getPolyfill() {\n\tif (!Object.assign) {\n\t\treturn implementation;\n\t}\n\tif (lacksProperEnumerationOrder()) {\n\t\treturn implementation;\n\t}\n\tif (assignHasPendingExceptions()) {\n\t\treturn implementation;\n\t}\n\treturn Object.assign;\n};\n\n\n//# sourceURL=webpack:///./node_modules/object.assign/polyfill.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/object.assign/shim.js":
|
|
/*!********************************************!*\
|
|
!*** ./node_modules/object.assign/shim.js ***!
|
|
\********************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\nvar define = __webpack_require__(/*! define-properties */ \"./node_modules/define-properties/index.js\");\nvar getPolyfill = __webpack_require__(/*! ./polyfill */ \"./node_modules/object.assign/polyfill.js\");\n\nmodule.exports = function shimAssign() {\n\tvar polyfill = getPolyfill();\n\tdefine(\n\t\tObject,\n\t\t{ assign: polyfill },\n\t\t{ assign: function () { return Object.assign !== polyfill; } }\n\t);\n\treturn polyfill;\n};\n\n\n//# sourceURL=webpack:///./node_modules/object.assign/shim.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/process/browser.js":
|
|
/*!*****************************************!*\
|
|
!*** ./node_modules/process/browser.js ***!
|
|
\*****************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports) {
|
|
|
|
eval("// shim for using process in browser\nvar process = module.exports = {};\n\n// cached from whatever global is present so that test runners that stub it\n// don't break things. But we need to wrap it in a try catch in case it is\n// wrapped in strict mode code which doesn't define any globals. It's inside a\n// function because try/catches deoptimize in certain engines.\n\nvar cachedSetTimeout;\nvar cachedClearTimeout;\n\nfunction defaultSetTimout() {\n throw new Error('setTimeout has not been defined');\n}\nfunction defaultClearTimeout () {\n throw new Error('clearTimeout has not been defined');\n}\n(function () {\n try {\n if (typeof setTimeout === 'function') {\n cachedSetTimeout = setTimeout;\n } else {\n cachedSetTimeout = defaultSetTimout;\n }\n } catch (e) {\n cachedSetTimeout = defaultSetTimout;\n }\n try {\n if (typeof clearTimeout === 'function') {\n cachedClearTimeout = clearTimeout;\n } else {\n cachedClearTimeout = defaultClearTimeout;\n }\n } catch (e) {\n cachedClearTimeout = defaultClearTimeout;\n }\n} ())\nfunction runTimeout(fun) {\n if (cachedSetTimeout === setTimeout) {\n //normal enviroments in sane situations\n return setTimeout(fun, 0);\n }\n // if setTimeout wasn't available but was latter defined\n if ((cachedSetTimeout === defaultSetTimout || !cachedSetTimeout) && setTimeout) {\n cachedSetTimeout = setTimeout;\n return setTimeout(fun, 0);\n }\n try {\n // when when somebody has screwed with setTimeout but no I.E. maddness\n return cachedSetTimeout(fun, 0);\n } catch(e){\n try {\n // When we are in I.E. but the script has been evaled so I.E. doesn't trust the global object when called normally\n return cachedSetTimeout.call(null, fun, 0);\n } catch(e){\n // same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error\n return cachedSetTimeout.call(this, fun, 0);\n }\n }\n\n\n}\nfunction runClearTimeout(marker) {\n if (cachedClearTimeout === clearTimeout) {\n //normal enviroments in sane situations\n return clearTimeout(marker);\n }\n // if clearTimeout wasn't available but was latter defined\n if ((cachedClearTimeout === defaultClearTimeout || !cachedClearTimeout) && clearTimeout) {\n cachedClearTimeout = clearTimeout;\n return clearTimeout(marker);\n }\n try {\n // when when somebody has screwed with setTimeout but no I.E. maddness\n return cachedClearTimeout(marker);\n } catch (e){\n try {\n // When we are in I.E. but the script has been evaled so I.E. doesn't trust the global object when called normally\n return cachedClearTimeout.call(null, marker);\n } catch (e){\n // same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error.\n // Some versions of I.E. have different rules for clearTimeout vs setTimeout\n return cachedClearTimeout.call(this, marker);\n }\n }\n\n\n\n}\nvar queue = [];\nvar draining = false;\nvar currentQueue;\nvar queueIndex = -1;\n\nfunction cleanUpNextTick() {\n if (!draining || !currentQueue) {\n return;\n }\n draining = false;\n if (currentQueue.length) {\n queue = currentQueue.concat(queue);\n } else {\n queueIndex = -1;\n }\n if (queue.length) {\n drainQueue();\n }\n}\n\nfunction drainQueue() {\n if (draining) {\n return;\n }\n var timeout = runTimeout(cleanUpNextTick);\n draining = true;\n\n var len = queue.length;\n while(len) {\n currentQueue = queue;\n queue = [];\n while (++queueIndex < len) {\n if (currentQueue) {\n currentQueue[queueIndex].run();\n }\n }\n queueIndex = -1;\n len = queue.length;\n }\n currentQueue = null;\n draining = false;\n runClearTimeout(timeout);\n}\n\nprocess.nextTick = function (fun) {\n var args = new Array(arguments.length - 1);\n if (arguments.length > 1) {\n for (var i = 1; i < arguments.length; i++) {\n args[i - 1] = arguments[i];\n }\n }\n queue.push(new Item(fun, args));\n if (queue.length === 1 && !draining) {\n runTimeout(drainQueue);\n }\n};\n\n// v8 likes predictible objects\nfunction Item(fun, array) {\n this.fun = fun;\n this.array = array;\n}\nItem.prototype.run = function () {\n this.fun.apply(null, this.array);\n};\nprocess.title = 'browser';\nprocess.browser = true;\nprocess.env = {};\nprocess.argv = [];\nprocess.version = ''; // empty string to avoid regexp issues\nprocess.versions = {};\n\nfunction noop() {}\n\nprocess.on = noop;\nprocess.addListener = noop;\nprocess.once = noop;\nprocess.off = noop;\nprocess.removeListener = noop;\nprocess.removeAllListeners = noop;\nprocess.emit = noop;\nprocess.prependListener = noop;\nprocess.prependOnceListener = noop;\n\nprocess.listeners = function (name) { return [] }\n\nprocess.binding = function (name) {\n throw new Error('process.binding is not supported');\n};\n\nprocess.cwd = function () { return '/' };\nprocess.chdir = function (dir) {\n throw new Error('process.chdir is not supported');\n};\nprocess.umask = function() { return 0; };\n\n\n//# sourceURL=webpack:///./node_modules/process/browser.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/regexp.prototype.flags/implementation.js":
|
|
/*!***************************************************************!*\
|
|
!*** ./node_modules/regexp.prototype.flags/implementation.js ***!
|
|
\***************************************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\nvar $Object = Object;\nvar $TypeError = TypeError;\n\nmodule.exports = function flags() {\n\tif (this != null && this !== $Object(this)) {\n\t\tthrow new $TypeError('RegExp.prototype.flags getter called on non-object');\n\t}\n\tvar result = '';\n\tif (this.global) {\n\t\tresult += 'g';\n\t}\n\tif (this.ignoreCase) {\n\t\tresult += 'i';\n\t}\n\tif (this.multiline) {\n\t\tresult += 'm';\n\t}\n\tif (this.dotAll) {\n\t\tresult += 's';\n\t}\n\tif (this.unicode) {\n\t\tresult += 'u';\n\t}\n\tif (this.sticky) {\n\t\tresult += 'y';\n\t}\n\treturn result;\n};\n\n\n//# sourceURL=webpack:///./node_modules/regexp.prototype.flags/implementation.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/regexp.prototype.flags/index.js":
|
|
/*!******************************************************!*\
|
|
!*** ./node_modules/regexp.prototype.flags/index.js ***!
|
|
\******************************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\nvar define = __webpack_require__(/*! define-properties */ \"./node_modules/define-properties/index.js\");\nvar callBind = __webpack_require__(/*! es-abstract/helpers/callBind */ \"./node_modules/es-abstract/helpers/callBind.js\");\n\nvar implementation = __webpack_require__(/*! ./implementation */ \"./node_modules/regexp.prototype.flags/implementation.js\");\nvar getPolyfill = __webpack_require__(/*! ./polyfill */ \"./node_modules/regexp.prototype.flags/polyfill.js\");\nvar shim = __webpack_require__(/*! ./shim */ \"./node_modules/regexp.prototype.flags/shim.js\");\n\nvar flagsBound = callBind(implementation);\n\ndefine(flagsBound, {\n\tgetPolyfill: getPolyfill,\n\timplementation: implementation,\n\tshim: shim\n});\n\nmodule.exports = flagsBound;\n\n\n//# sourceURL=webpack:///./node_modules/regexp.prototype.flags/index.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/regexp.prototype.flags/polyfill.js":
|
|
/*!*********************************************************!*\
|
|
!*** ./node_modules/regexp.prototype.flags/polyfill.js ***!
|
|
\*********************************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\nvar implementation = __webpack_require__(/*! ./implementation */ \"./node_modules/regexp.prototype.flags/implementation.js\");\n\nvar supportsDescriptors = __webpack_require__(/*! define-properties */ \"./node_modules/define-properties/index.js\").supportsDescriptors;\nvar $gOPD = Object.getOwnPropertyDescriptor;\nvar $TypeError = TypeError;\n\nmodule.exports = function getPolyfill() {\n\tif (!supportsDescriptors) {\n\t\tthrow new $TypeError('RegExp.prototype.flags requires a true ES5 environment that supports property descriptors');\n\t}\n\tif ((/a/mig).flags === 'gim') {\n\t\tvar descriptor = $gOPD(RegExp.prototype, 'flags');\n\t\tif (descriptor && typeof descriptor.get === 'function' && typeof (/a/).dotAll === 'boolean') {\n\t\t\treturn descriptor.get;\n\t\t}\n\t}\n\treturn implementation;\n};\n\n\n//# sourceURL=webpack:///./node_modules/regexp.prototype.flags/polyfill.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/regexp.prototype.flags/shim.js":
|
|
/*!*****************************************************!*\
|
|
!*** ./node_modules/regexp.prototype.flags/shim.js ***!
|
|
\*****************************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\nvar supportsDescriptors = __webpack_require__(/*! define-properties */ \"./node_modules/define-properties/index.js\").supportsDescriptors;\nvar getPolyfill = __webpack_require__(/*! ./polyfill */ \"./node_modules/regexp.prototype.flags/polyfill.js\");\nvar gOPD = Object.getOwnPropertyDescriptor;\nvar defineProperty = Object.defineProperty;\nvar TypeErr = TypeError;\nvar getProto = Object.getPrototypeOf;\nvar regex = /a/;\n\nmodule.exports = function shimFlags() {\n\tif (!supportsDescriptors || !getProto) {\n\t\tthrow new TypeErr('RegExp.prototype.flags requires a true ES5 environment that supports property descriptors');\n\t}\n\tvar polyfill = getPolyfill();\n\tvar proto = getProto(regex);\n\tvar descriptor = gOPD(proto, 'flags');\n\tif (!descriptor || descriptor.get !== polyfill) {\n\t\tdefineProperty(proto, 'flags', {\n\t\t\tconfigurable: true,\n\t\t\tenumerable: false,\n\t\t\tget: polyfill\n\t\t});\n\t}\n\treturn polyfill;\n};\n\n\n//# sourceURL=webpack:///./node_modules/regexp.prototype.flags/shim.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/side-channel/index.js":
|
|
/*!********************************************!*\
|
|
!*** ./node_modules/side-channel/index.js ***!
|
|
\********************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\nvar GetIntrinsic = __webpack_require__(/*! es-abstract/GetIntrinsic */ \"./node_modules/es-abstract/GetIntrinsic.js\");\nvar callBound = __webpack_require__(/*! es-abstract/helpers/callBound */ \"./node_modules/es-abstract/helpers/callBound.js\");\nvar inspect = __webpack_require__(/*! object-inspect */ \"./node_modules/object-inspect/index.js\");\n\nvar $TypeError = GetIntrinsic('%TypeError%');\nvar $WeakMap = GetIntrinsic('%WeakMap%', true);\nvar $Map = GetIntrinsic('%Map%', true);\nvar $push = callBound('Array.prototype.push');\n\nvar $weakMapGet = callBound('WeakMap.prototype.get', true);\nvar $weakMapSet = callBound('WeakMap.prototype.set', true);\nvar $weakMapHas = callBound('WeakMap.prototype.has', true);\nvar $mapGet = callBound('Map.prototype.get', true);\nvar $mapSet = callBound('Map.prototype.set', true);\nvar $mapHas = callBound('Map.prototype.has', true);\nvar objectGet = function (objects, key) { // eslint-disable-line consistent-return\n\tfor (var i = 0; i < objects.length; i += 1) {\n\t\tif (objects[i].key === key) {\n\t\t\treturn objects[i].value;\n\t\t}\n\t}\n};\nvar objectSet = function (objects, key, value) {\n\tfor (var i = 0; i < objects.length; i += 1) {\n\t\tif (objects[i].key === key) {\n\t\t\tobjects[i].value = value; // eslint-disable-line no-param-reassign\n\t\t\treturn;\n\t\t}\n\t}\n\t$push(objects, {\n\t\tkey: key,\n\t\tvalue: value\n\t});\n};\nvar objectHas = function (objects, key) {\n\tfor (var i = 0; i < objects.length; i += 1) {\n\t\tif (objects[i].key === key) {\n\t\t\treturn true;\n\t\t}\n\t}\n\treturn false;\n};\n\nmodule.exports = function getSideChannel() {\n\tvar $wm;\n\tvar $m;\n\tvar $o;\n\tvar channel = {\n\t\tassert: function (key) {\n\t\t\tif (!channel.has(key)) {\n\t\t\t\tthrow new $TypeError('Side channel does not contain ' + inspect(key));\n\t\t\t}\n\t\t},\n\t\tget: function (key) { // eslint-disable-line consistent-return\n\t\t\tif ($WeakMap && key && (typeof key === 'object' || typeof key === 'function')) {\n\t\t\t\tif ($wm) {\n\t\t\t\t\treturn $weakMapGet($wm, key);\n\t\t\t\t}\n\t\t\t} else if ($Map) {\n\t\t\t\tif ($m) {\n\t\t\t\t\treturn $mapGet($m, key);\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tif ($o) { // eslint-disable-line no-lonely-if\n\t\t\t\t\treturn objectGet($o, key);\n\t\t\t\t}\n\t\t\t}\n\t\t},\n\t\thas: function (key) {\n\t\t\tif ($WeakMap && key && (typeof key === 'object' || typeof key === 'function')) {\n\t\t\t\tif ($wm) {\n\t\t\t\t\treturn $weakMapHas($wm, key);\n\t\t\t\t}\n\t\t\t} else if ($Map) {\n\t\t\t\tif ($m) {\n\t\t\t\t\treturn $mapHas($m, key);\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tif ($o) { // eslint-disable-line no-lonely-if\n\t\t\t\t\treturn objectHas($o, key);\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn false;\n\t\t},\n\t\tset: function (key, value) {\n\t\t\tif ($WeakMap && key && (typeof key === 'object' || typeof key === 'function')) {\n\t\t\t\tif (!$wm) {\n\t\t\t\t\t$wm = new $WeakMap();\n\t\t\t\t}\n\t\t\t\t$weakMapSet($wm, key, value);\n\t\t\t} else if ($Map) {\n\t\t\t\tif (!$m) {\n\t\t\t\t\t$m = new $Map();\n\t\t\t\t}\n\t\t\t\t$mapSet($m, key, value);\n\t\t\t} else {\n\t\t\t\tif (!$o) {\n\t\t\t\t\t$o = [];\n\t\t\t\t}\n\t\t\t\tobjectSet($o, key, value);\n\t\t\t}\n\t\t}\n\t};\n\treturn channel;\n};\n\n\n//# sourceURL=webpack:///./node_modules/side-channel/index.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/simple-swizzle/index.js":
|
|
/*!**********************************************!*\
|
|
!*** ./node_modules/simple-swizzle/index.js ***!
|
|
\**********************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\nvar isArrayish = __webpack_require__(/*! is-arrayish */ \"./node_modules/is-arrayish/index.js\");\n\nvar concat = Array.prototype.concat;\nvar slice = Array.prototype.slice;\n\nvar swizzle = module.exports = function swizzle(args) {\n\tvar results = [];\n\n\tfor (var i = 0, len = args.length; i < len; i++) {\n\t\tvar arg = args[i];\n\n\t\tif (isArrayish(arg)) {\n\t\t\t// http://jsperf.com/javascript-array-concat-vs-push/98\n\t\t\tresults = concat.call(results, slice.call(arg));\n\t\t} else {\n\t\t\tresults.push(arg);\n\t\t}\n\t}\n\n\treturn results;\n};\n\nswizzle.wrap = function (fn) {\n\treturn function () {\n\t\treturn fn(swizzle(arguments));\n\t};\n};\n\n\n//# sourceURL=webpack:///./node_modules/simple-swizzle/index.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/tslib/tslib.es6.js":
|
|
/*!*****************************************!*\
|
|
!*** ./node_modules/tslib/tslib.es6.js ***!
|
|
\*****************************************/
|
|
/*! exports provided: __extends, __assign, __rest, __decorate, __param, __metadata, __awaiter, __generator, __createBinding, __exportStar, __values, __read, __spread, __spreadArrays, __await, __asyncGenerator, __asyncDelegator, __asyncValues, __makeTemplateObject, __importStar, __importDefault, __classPrivateFieldGet, __classPrivateFieldSet */
|
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"__extends\", function() { return __extends; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"__assign\", function() { return __assign; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"__rest\", function() { return __rest; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"__decorate\", function() { return __decorate; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"__param\", function() { return __param; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"__metadata\", function() { return __metadata; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"__awaiter\", function() { return __awaiter; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"__generator\", function() { return __generator; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"__createBinding\", function() { return __createBinding; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"__exportStar\", function() { return __exportStar; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"__values\", function() { return __values; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"__read\", function() { return __read; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"__spread\", function() { return __spread; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"__spreadArrays\", function() { return __spreadArrays; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"__await\", function() { return __await; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"__asyncGenerator\", function() { return __asyncGenerator; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"__asyncDelegator\", function() { return __asyncDelegator; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"__asyncValues\", function() { return __asyncValues; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"__makeTemplateObject\", function() { return __makeTemplateObject; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"__importStar\", function() { return __importStar; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"__importDefault\", function() { return __importDefault; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"__classPrivateFieldGet\", function() { return __classPrivateFieldGet; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"__classPrivateFieldSet\", function() { return __classPrivateFieldSet; });\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation.\r\n\r\nPermission to use, copy, modify, and/or distribute this software for any\r\npurpose with or without fee is hereby granted.\r\n\r\nTHE SOFTWARE IS PROVIDED \"AS IS\" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH\r\nREGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY\r\nAND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,\r\nINDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM\r\nLOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR\r\nOTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR\r\nPERFORMANCE OF THIS SOFTWARE.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\r\n\r\nvar __assign = function() {\r\n __assign = Object.assign || function __assign(t) {\r\n for (var s, i = 1, n = arguments.length; i < n; i++) {\r\n s = arguments[i];\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];\r\n }\r\n return t;\r\n }\r\n return __assign.apply(this, arguments);\r\n}\r\n\r\nfunction __rest(s, e) {\r\n var t = {};\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)\r\n t[p] = s[p];\r\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\")\r\n for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\r\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))\r\n t[p[i]] = s[p[i]];\r\n }\r\n return t;\r\n}\r\n\r\nfunction __decorate(decorators, target, key, desc) {\r\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\r\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\r\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\r\n return c > 3 && r && Object.defineProperty(target, key, r), r;\r\n}\r\n\r\nfunction __param(paramIndex, decorator) {\r\n return function (target, key) { decorator(target, key, paramIndex); }\r\n}\r\n\r\nfunction __metadata(metadataKey, metadataValue) {\r\n if (typeof Reflect === \"object\" && typeof Reflect.metadata === \"function\") return Reflect.metadata(metadataKey, metadataValue);\r\n}\r\n\r\nfunction __awaiter(thisArg, _arguments, P, generator) {\r\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\r\n return new (P || (P = Promise))(function (resolve, reject) {\r\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\r\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\r\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\r\n step((generator = generator.apply(thisArg, _arguments || [])).next());\r\n });\r\n}\r\n\r\nfunction __generator(thisArg, body) {\r\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\r\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\r\n function verb(n) { return function (v) { return step([n, v]); }; }\r\n function step(op) {\r\n if (f) throw new TypeError(\"Generator is already executing.\");\r\n while (_) try {\r\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\r\n if (y = 0, t) op = [op[0] & 2, t.value];\r\n switch (op[0]) {\r\n case 0: case 1: t = op; break;\r\n case 4: _.label++; return { value: op[1], done: false };\r\n case 5: _.label++; y = op[1]; op = [0]; continue;\r\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\r\n default:\r\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\r\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\r\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\r\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\r\n if (t[2]) _.ops.pop();\r\n _.trys.pop(); continue;\r\n }\r\n op = body.call(thisArg, _);\r\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\r\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\r\n }\r\n}\r\n\r\nfunction __createBinding(o, m, k, k2) {\r\n if (k2 === undefined) k2 = k;\r\n o[k2] = m[k];\r\n}\r\n\r\nfunction __exportStar(m, exports) {\r\n for (var p in m) if (p !== \"default\" && !exports.hasOwnProperty(p)) exports[p] = m[p];\r\n}\r\n\r\nfunction __values(o) {\r\n var s = typeof Symbol === \"function\" && Symbol.iterator, m = s && o[s], i = 0;\r\n if (m) return m.call(o);\r\n if (o && typeof o.length === \"number\") return {\r\n next: function () {\r\n if (o && i >= o.length) o = void 0;\r\n return { value: o && o[i++], done: !o };\r\n }\r\n };\r\n throw new TypeError(s ? \"Object is not iterable.\" : \"Symbol.iterator is not defined.\");\r\n}\r\n\r\nfunction __read(o, n) {\r\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\r\n if (!m) return o;\r\n var i = m.call(o), r, ar = [], e;\r\n try {\r\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\r\n }\r\n catch (error) { e = { error: error }; }\r\n finally {\r\n try {\r\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\r\n }\r\n finally { if (e) throw e.error; }\r\n }\r\n return ar;\r\n}\r\n\r\nfunction __spread() {\r\n for (var ar = [], i = 0; i < arguments.length; i++)\r\n ar = ar.concat(__read(arguments[i]));\r\n return ar;\r\n}\r\n\r\nfunction __spreadArrays() {\r\n for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;\r\n for (var r = Array(s), k = 0, i = 0; i < il; i++)\r\n for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)\r\n r[k] = a[j];\r\n return r;\r\n};\r\n\r\nfunction __await(v) {\r\n return this instanceof __await ? (this.v = v, this) : new __await(v);\r\n}\r\n\r\nfunction __asyncGenerator(thisArg, _arguments, generator) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var g = generator.apply(thisArg, _arguments || []), i, q = [];\r\n return i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i;\r\n function verb(n) { if (g[n]) i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; }\r\n function resume(n, v) { try { step(g[n](v)); } catch (e) { settle(q[0][3], e); } }\r\n function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); }\r\n function fulfill(value) { resume(\"next\", value); }\r\n function reject(value) { resume(\"throw\", value); }\r\n function settle(f, v) { if (f(v), q.shift(), q.length) resume(q[0][0], q[0][1]); }\r\n}\r\n\r\nfunction __asyncDelegator(o) {\r\n var i, p;\r\n return i = {}, verb(\"next\"), verb(\"throw\", function (e) { throw e; }), verb(\"return\"), i[Symbol.iterator] = function () { return this; }, i;\r\n function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: n === \"return\" } : f ? f(v) : v; } : f; }\r\n}\r\n\r\nfunction __asyncValues(o) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var m = o[Symbol.asyncIterator], i;\r\n return m ? m.call(o) : (o = typeof __values === \"function\" ? __values(o) : o[Symbol.iterator](), i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i);\r\n function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; }\r\n function settle(resolve, reject, d, v) { Promise.resolve(v).then(function(v) { resolve({ value: v, done: d }); }, reject); }\r\n}\r\n\r\nfunction __makeTemplateObject(cooked, raw) {\r\n if (Object.defineProperty) { Object.defineProperty(cooked, \"raw\", { value: raw }); } else { cooked.raw = raw; }\r\n return cooked;\r\n};\r\n\r\nfunction __importStar(mod) {\r\n if (mod && mod.__esModule) return mod;\r\n var result = {};\r\n if (mod != null) for (var k in mod) if (Object.hasOwnProperty.call(mod, k)) result[k] = mod[k];\r\n result.default = mod;\r\n return result;\r\n}\r\n\r\nfunction __importDefault(mod) {\r\n return (mod && mod.__esModule) ? mod : { default: mod };\r\n}\r\n\r\nfunction __classPrivateFieldGet(receiver, privateMap) {\r\n if (!privateMap.has(receiver)) {\r\n throw new TypeError(\"attempted to get private field on non-instance\");\r\n }\r\n return privateMap.get(receiver);\r\n}\r\n\r\nfunction __classPrivateFieldSet(receiver, privateMap, value) {\r\n if (!privateMap.has(receiver)) {\r\n throw new TypeError(\"attempted to set private field on non-instance\");\r\n }\r\n privateMap.set(receiver, value);\r\n return value;\r\n}\r\n\n\n//# sourceURL=webpack:///./node_modules/tslib/tslib.es6.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/webmidi/webmidi.min.js":
|
|
/*!*********************************************!*\
|
|
!*** ./node_modules/webmidi/webmidi.min.js ***!
|
|
\*********************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
eval("var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/*\n\nWebMidi v2.3.0\n\nWebMidi.js helps you tame the Web MIDI API. Send and receive MIDI messages with ease. Control instruments with user-friendly functions (playNote, sendPitchBend, etc.). React to MIDI input with simple event listeners (noteon, pitchbend, controlchange, etc.).\nhttps://github.com/djipco/webmidi\n\n\nThe MIT License (MIT)\n\nCopyright (c) 2015-2018, Jean-Philippe Côté\n\nPermission is hereby granted, free of charge, to any person obtaining a copy of this software and\nassociated documentation files (the \"Software\"), to deal in the Software without restriction,\nincluding without limitation the rights to use, copy, modify, merge, publish, distribute,\nsublicense, and/or sell copies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all copies or substantial\nportions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT\nNOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\nNONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES\nOR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN\nCONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n\n*/\n\n!function(scope){\"use strict\";function WebMidi(){if(WebMidi.prototype._singleton)throw new Error(\"WebMidi is a singleton, it cannot be instantiated directly.\");WebMidi.prototype._singleton=this,this._inputs=[],this._outputs=[],this._userHandlers={},this._stateChangeQueue=[],this._processingStateChange=!1,this._midiInterfaceEvents=[\"connected\",\"disconnected\"],this._notes=[\"C\",\"C#\",\"D\",\"D#\",\"E\",\"F\",\"F#\",\"G\",\"G#\",\"A\",\"A#\",\"B\"],this._semitones={C:0,D:2,E:4,F:5,G:7,A:9,B:11},Object.defineProperties(this,{MIDI_SYSTEM_MESSAGES:{value:{sysex:240,timecode:241,songposition:242,songselect:243,tuningrequest:246,sysexend:247,clock:248,start:250,\"continue\":251,stop:252,activesensing:254,reset:255,midimessage:0,unknownsystemmessage:-1},writable:!1,enumerable:!0,configurable:!1},MIDI_CHANNEL_MESSAGES:{value:{noteoff:8,noteon:9,keyaftertouch:10,controlchange:11,channelmode:11,programchange:12,channelaftertouch:13,pitchbend:14},writable:!1,enumerable:!0,configurable:!1},MIDI_REGISTERED_PARAMETER:{value:{pitchbendrange:[0,0],channelfinetuning:[0,1],channelcoarsetuning:[0,2],tuningprogram:[0,3],tuningbank:[0,4],modulationrange:[0,5],azimuthangle:[61,0],elevationangle:[61,1],gain:[61,2],distanceratio:[61,3],maximumdistance:[61,4],maximumdistancegain:[61,5],referencedistanceratio:[61,6],panspreadangle:[61,7],rollangle:[61,8]},writable:!1,enumerable:!0,configurable:!1},MIDI_CONTROL_CHANGE_MESSAGES:{value:{bankselectcoarse:0,modulationwheelcoarse:1,breathcontrollercoarse:2,footcontrollercoarse:4,portamentotimecoarse:5,dataentrycoarse:6,volumecoarse:7,balancecoarse:8,pancoarse:10,expressioncoarse:11,effectcontrol1coarse:12,effectcontrol2coarse:13,generalpurposeslider1:16,generalpurposeslider2:17,generalpurposeslider3:18,generalpurposeslider4:19,bankselectfine:32,modulationwheelfine:33,breathcontrollerfine:34,footcontrollerfine:36,portamentotimefine:37,dataentryfine:38,volumefine:39,balancefine:40,panfine:42,expressionfine:43,effectcontrol1fine:44,effectcontrol2fine:45,holdpedal:64,portamento:65,sustenutopedal:66,softpedal:67,legatopedal:68,hold2pedal:69,soundvariation:70,resonance:71,soundreleasetime:72,soundattacktime:73,brightness:74,soundcontrol6:75,soundcontrol7:76,soundcontrol8:77,soundcontrol9:78,soundcontrol10:79,generalpurposebutton1:80,generalpurposebutton2:81,generalpurposebutton3:82,generalpurposebutton4:83,reverblevel:91,tremololevel:92,choruslevel:93,celestelevel:94,phaserlevel:95,databuttonincrement:96,databuttondecrement:97,nonregisteredparametercoarse:98,nonregisteredparameterfine:99,registeredparametercoarse:100,registeredparameterfine:101},writable:!1,enumerable:!0,configurable:!1},MIDI_CHANNEL_MODE_MESSAGES:{value:{allsoundoff:120,resetallcontrollers:121,localcontrol:122,allnotesoff:123,omnimodeoff:124,omnimodeon:125,monomodeon:126,polymodeon:127},writable:!1,enumerable:!0,configurable:!1},octaveOffset:{value:0,writable:!0,enumerable:!0,configurable:!1}}),Object.defineProperties(this,{supported:{enumerable:!0,get:function(){return\"requestMIDIAccess\"in navigator}},enabled:{enumerable:!0,get:function(){return void 0!==this[\"interface\"]}.bind(this)},inputs:{enumerable:!0,get:function(){return this._inputs}.bind(this)},outputs:{enumerable:!0,get:function(){return this._outputs}.bind(this)},sysexEnabled:{enumerable:!0,get:function(){return!(!this[\"interface\"]||!this[\"interface\"].sysexEnabled)}.bind(this)},time:{enumerable:!0,get:function(){return performance.now()}}})}function Input(midiInput){var that=this;this._userHandlers={channel:{},system:{}},this._midiInput=midiInput,Object.defineProperties(this,{connection:{enumerable:!0,get:function(){return that._midiInput.connection}},id:{enumerable:!0,get:function(){return that._midiInput.id}},manufacturer:{enumerable:!0,get:function(){return that._midiInput.manufacturer}},name:{enumerable:!0,get:function(){return that._midiInput.name}},state:{enumerable:!0,get:function(){return that._midiInput.state}},type:{enumerable:!0,get:function(){return that._midiInput.type}}}),this._initializeUserHandlers(),this._midiInput.onmidimessage=this._onMidiMessage.bind(this)}function Output(midiOutput){var that=this;this._midiOutput=midiOutput,Object.defineProperties(this,{connection:{enumerable:!0,get:function(){return that._midiOutput.connection}},id:{enumerable:!0,get:function(){return that._midiOutput.id}},manufacturer:{enumerable:!0,get:function(){return that._midiOutput.manufacturer}},name:{enumerable:!0,get:function(){return that._midiOutput.name}},state:{enumerable:!0,get:function(){return that._midiOutput.state}},type:{enumerable:!0,get:function(){return that._midiOutput.type}}})}var wm=new WebMidi;WebMidi.prototype.enable=function(callback,sysex){return this.enabled?void 0:this.supported?void navigator.requestMIDIAccess({sysex:sysex}).then(function(midiAccess){function onPortsOpen(){clearTimeout(promiseTimeout),this._updateInputsAndOutputs(),this[\"interface\"].onstatechange=this._onInterfaceStateChange.bind(this),\"function\"==typeof callback&&callback.call(this),events.forEach(function(event){this._onInterfaceStateChange(event)}.bind(this))}var promiseTimeout,events=[],promises=[];this[\"interface\"]=midiAccess,this._resetInterfaceUserHandlers(),this[\"interface\"].onstatechange=function(e){events.push(e)};for(var inputs=midiAccess.inputs.values(),input=inputs.next();input&&!input.done;input=inputs.next())promises.push(input.value.open());for(var outputs=midiAccess.outputs.values(),output=outputs.next();output&&!output.done;output=outputs.next())promises.push(output.value.open());promiseTimeout=setTimeout(onPortsOpen.bind(this),200),Promise&&Promise.all(promises)[\"catch\"](function(err){}).then(onPortsOpen.bind(this))}.bind(this),function(err){\"function\"==typeof callback&&callback.call(this,err)}.bind(this)):void(\"function\"==typeof callback&&callback(new Error(\"The Web MIDI API is not supported by your browser.\")))},WebMidi.prototype.disable=function(){if(!this.supported)throw new Error(\"The Web MIDI API is not supported by your browser.\");this[\"interface\"]&&(this[\"interface\"].onstatechange=void 0),this[\"interface\"]=void 0,this._inputs=[],this._outputs=[],this._resetInterfaceUserHandlers()},WebMidi.prototype.addListener=function(type,listener){if(!this.enabled)throw new Error(\"WebMidi must be enabled before adding event listeners.\");if(\"function\"!=typeof listener)throw new TypeError(\"The 'listener' parameter must be a function.\");if(!(this._midiInterfaceEvents.indexOf(type)>=0))throw new TypeError(\"The specified event type is not supported.\");return this._userHandlers[type].push(listener),this},WebMidi.prototype.hasListener=function(type,listener){if(!this.enabled)throw new Error(\"WebMidi must be enabled before checking event listeners.\");if(\"function\"!=typeof listener)throw new TypeError(\"The 'listener' parameter must be a function.\");if(!(this._midiInterfaceEvents.indexOf(type)>=0))throw new TypeError(\"The specified event type is not supported.\");for(var o=0;o<this._userHandlers[type].length;o++)if(this._userHandlers[type][o]===listener)return!0;return!1},WebMidi.prototype.removeListener=function(type,listener){if(!this.enabled)throw new Error(\"WebMidi must be enabled before removing event listeners.\");if(void 0!==listener&&\"function\"!=typeof listener)throw new TypeError(\"The 'listener' parameter must be a function.\");if(this._midiInterfaceEvents.indexOf(type)>=0)if(listener)for(var o=0;o<this._userHandlers[type].length;o++)this._userHandlers[type][o]===listener&&this._userHandlers[type].splice(o,1);else this._userHandlers[type]=[];else{if(void 0!==type)throw new TypeError(\"The specified event type is not supported.\");this._resetInterfaceUserHandlers()}return this},WebMidi.prototype.toMIDIChannels=function(channel){var channels;return channels=\"all\"===channel||void 0===channel?[\"all\"]:Array.isArray(channel)?channel:[channel],channels.indexOf(\"all\")>-1&&(channels=[1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16]),channels.map(function(ch){return parseInt(ch)}).filter(function(ch){return ch>=1&&16>=ch})},WebMidi.prototype.getInputById=function(id){if(!this.enabled)throw new Error(\"WebMidi is not enabled.\");for(var i=0;i<this.inputs.length;i++)if(this.inputs[i].id===id)return this.inputs[i];return!1},WebMidi.prototype.getOutputById=function(id){if(!this.enabled)throw new Error(\"WebMidi is not enabled.\");for(var i=0;i<this.outputs.length;i++)if(this.outputs[i].id===id)return this.outputs[i];return!1},WebMidi.prototype.getInputByName=function(name){if(!this.enabled)throw new Error(\"WebMidi is not enabled.\");for(var i=0;i<this.inputs.length;i++)if(~this.inputs[i].name.indexOf(name))return this.inputs[i];return!1},WebMidi.prototype.getOctave=function(number){return null!=number&&number>=0&&127>=number?Math.floor(Math.floor(number)/12-1)+Math.floor(wm.octaveOffset):void 0},WebMidi.prototype.getOutputByName=function(name){if(!this.enabled)throw new Error(\"WebMidi is not enabled.\");for(var i=0;i<this.outputs.length;i++)if(~this.outputs[i].name.indexOf(name))return this.outputs[i];return!1},WebMidi.prototype.guessNoteNumber=function(input){var output=!1;if(input&&input.toFixed&&input>=0&&127>=input?output=Math.round(input):parseInt(input)>=0&&parseInt(input)<=127?output=parseInt(input):(\"string\"==typeof input||input instanceof String)&&(output=this.noteNameToNumber(input)),output===!1)throw new Error(\"Invalid input value (\"+input+\").\");return output},WebMidi.prototype.noteNameToNumber=function(name){\"string\"!=typeof name&&(name=\"\");var matches=name.match(/([CDEFGAB])(#{0,2}|b{0,2})(-?\\d+)/i);if(!matches)throw new RangeError(\"Invalid note name.\");var semitones=wm._semitones[matches[1].toUpperCase()],octave=parseInt(matches[3]),result=12*(octave+1-Math.floor(wm.octaveOffset))+semitones;if(matches[2].toLowerCase().indexOf(\"b\")>-1?result-=matches[2].length:matches[2].toLowerCase().indexOf(\"#\")>-1&&(result+=matches[2].length),0>result||result>127)throw new RangeError(\"Invalid note name or note outside valid range.\");return result},WebMidi.prototype._updateInputsAndOutputs=function(){this._updateInputs(),this._updateOutputs()},WebMidi.prototype._updateInputs=function(){for(var i=0;i<this._inputs.length;i++){for(var remove=!0,updated=this[\"interface\"].inputs.values(),input=updated.next();input&&!input.done;input=updated.next())if(this._inputs[i]._midiInput===input.value){remove=!1;break}remove&&this._inputs.splice(i,1)}this[\"interface\"]&&this[\"interface\"].inputs.forEach(function(nInput){for(var add=!0,j=0;j<this._inputs.length;j++)this._inputs[j]._midiInput===nInput&&(add=!1);add&&this._inputs.push(new Input(nInput))}.bind(this))},WebMidi.prototype._updateOutputs=function(){for(var i=0;i<this._outputs.length;i++){for(var remove=!0,updated=this[\"interface\"].outputs.values(),output=updated.next();output&&!output.done;output=updated.next())if(this._outputs[i]._midiOutput===output.value){remove=!1;break}remove&&this._outputs.splice(i,1)}this[\"interface\"]&&this[\"interface\"].outputs.forEach(function(nOutput){for(var add=!0,j=0;j<this._outputs.length;j++)this._outputs[j]._midiOutput===nOutput&&(add=!1);add&&this._outputs.push(new Output(nOutput))}.bind(this))},WebMidi.prototype._onInterfaceStateChange=function(e){this._updateInputsAndOutputs();var event={timestamp:e.timeStamp,type:e.port.state};this[\"interface\"]&&\"connected\"===e.port.state?\"output\"===e.port.type?event.port=this.getOutputById(e.port.id):\"input\"===e.port.type&&(event.port=this.getInputById(e.port.id)):event.port={connection:\"closed\",id:e.port.id,manufacturer:e.port.manufacturer,name:e.port.name,state:e.port.state,type:e.port.type},this._userHandlers[e.port.state].forEach(function(handler){handler(event)})},WebMidi.prototype._resetInterfaceUserHandlers=function(){for(var i=0;i<this._midiInterfaceEvents.length;i++)this._userHandlers[this._midiInterfaceEvents[i]]=[]},Input.prototype.addListener=function(type,channel,listener){var that=this;if(void 0===channel&&(channel=\"all\"),Array.isArray(channel)||(channel=[channel]),channel.forEach(function(item){if(\"all\"!==item&&!(item>=1&&16>=item))throw new RangeError(\"The 'channel' parameter is invalid.\")}),\"function\"!=typeof listener)throw new TypeError(\"The 'listener' parameter must be a function.\");if(void 0!==wm.MIDI_SYSTEM_MESSAGES[type])this._userHandlers.system[type]||(this._userHandlers.system[type]=[]),this._userHandlers.system[type].push(listener);else{if(void 0===wm.MIDI_CHANNEL_MESSAGES[type])throw new TypeError(\"The specified event type is not supported.\");if(channel.indexOf(\"all\")>-1){channel=[];for(var j=1;16>=j;j++)channel.push(j)}this._userHandlers.channel[type]||(this._userHandlers.channel[type]=[]),channel.forEach(function(ch){that._userHandlers.channel[type][ch]||(that._userHandlers.channel[type][ch]=[]),that._userHandlers.channel[type][ch].push(listener)})}return this},Input.prototype.on=Input.prototype.addListener,Input.prototype.hasListener=function(type,channel,listener){var that=this;if(\"function\"!=typeof listener)throw new TypeError(\"The 'listener' parameter must be a function.\");if(void 0===channel&&(channel=\"all\"),channel.constructor!==Array&&(channel=[channel]),void 0!==wm.MIDI_SYSTEM_MESSAGES[type]){for(var o=0;o<this._userHandlers.system[type].length;o++)if(this._userHandlers.system[type][o]===listener)return!0}else if(void 0!==wm.MIDI_CHANNEL_MESSAGES[type]){if(channel.indexOf(\"all\")>-1){channel=[];for(var j=1;16>=j;j++)channel.push(j)}return this._userHandlers.channel[type]?channel.every(function(chNum){var listeners=that._userHandlers.channel[type][chNum];return listeners&&listeners.indexOf(listener)>-1}):!1}return!1},Input.prototype.removeListener=function(type,channel,listener){var that=this;if(void 0!==listener&&\"function\"!=typeof listener)throw new TypeError(\"The 'listener' parameter must be a function.\");if(void 0===channel&&(channel=\"all\"),channel.constructor!==Array&&(channel=[channel]),void 0!==wm.MIDI_SYSTEM_MESSAGES[type])if(void 0===listener)this._userHandlers.system[type]=[];else for(var o=0;o<this._userHandlers.system[type].length;o++)this._userHandlers.system[type][o]===listener&&this._userHandlers.system[type].splice(o,1);else if(void 0!==wm.MIDI_CHANNEL_MESSAGES[type]){if(channel.indexOf(\"all\")>-1){channel=[];for(var j=1;16>=j;j++)channel.push(j)}if(!this._userHandlers.channel[type])return this;channel.forEach(function(chNum){var listeners=that._userHandlers.channel[type][chNum];if(listeners)if(void 0===listener)that._userHandlers.channel[type][chNum]=[];else for(var l=0;l<listeners.length;l++)listeners[l]===listener&&listeners.splice(l,1)})}else{if(void 0!==type)throw new TypeError(\"The specified event type is not supported.\");this._initializeUserHandlers()}return this},Input.prototype._initializeUserHandlers=function(){for(var prop1 in wm.MIDI_CHANNEL_MESSAGES)wm.MIDI_CHANNEL_MESSAGES.hasOwnProperty(prop1)&&(this._userHandlers.channel[prop1]={});for(var prop2 in wm.MIDI_SYSTEM_MESSAGES)wm.MIDI_SYSTEM_MESSAGES.hasOwnProperty(prop2)&&(this._userHandlers.system[prop2]=[])},Input.prototype._onMidiMessage=function(e){if(this._userHandlers.system.midimessage.length>0){var event={target:this,data:e.data,timestamp:e.timeStamp,type:\"midimessage\"};this._userHandlers.system.midimessage.forEach(function(callback){callback(event)})}e.data[0]<240?this._parseChannelEvent(e):e.data[0]<=255&&this._parseSystemEvent(e)},Input.prototype._parseChannelEvent=function(e){var data1,data2,command=e.data[0]>>4,channel=(15&e.data[0])+1;e.data.length>1&&(data1=e.data[1],data2=e.data.length>2?e.data[2]:void 0);var event={target:this,data:e.data,timestamp:e.timeStamp,channel:channel};command===wm.MIDI_CHANNEL_MESSAGES.noteoff||command===wm.MIDI_CHANNEL_MESSAGES.noteon&&0===data2?(event.type=\"noteoff\",event.note={number:data1,name:wm._notes[data1%12],octave:wm.getOctave(data1)},event.velocity=data2/127,event.rawVelocity=data2):command===wm.MIDI_CHANNEL_MESSAGES.noteon?(event.type=\"noteon\",event.note={number:data1,name:wm._notes[data1%12],octave:wm.getOctave(data1)},event.velocity=data2/127,event.rawVelocity=data2):command===wm.MIDI_CHANNEL_MESSAGES.keyaftertouch?(event.type=\"keyaftertouch\",event.note={number:data1,name:wm._notes[data1%12],octave:wm.getOctave(data1)},event.value=data2/127):command===wm.MIDI_CHANNEL_MESSAGES.controlchange&&data1>=0&&119>=data1?(event.type=\"controlchange\",event.controller={number:data1,name:this.getCcNameByNumber(data1)},event.value=data2):command===wm.MIDI_CHANNEL_MESSAGES.channelmode&&data1>=120&&127>=data1?(event.type=\"channelmode\",event.controller={number:data1,name:this.getChannelModeByNumber(data1)},event.value=data2):command===wm.MIDI_CHANNEL_MESSAGES.programchange?(event.type=\"programchange\",event.value=data1):command===wm.MIDI_CHANNEL_MESSAGES.channelaftertouch?(event.type=\"channelaftertouch\",event.value=data1/127):command===wm.MIDI_CHANNEL_MESSAGES.pitchbend?(event.type=\"pitchbend\",event.value=((data2<<7)+data1-8192)/8192):event.type=\"unknownchannelmessage\",this._userHandlers.channel[event.type]&&this._userHandlers.channel[event.type][channel]&&this._userHandlers.channel[event.type][channel].forEach(function(callback){callback(event)})},Input.prototype.getCcNameByNumber=function(number){if(number=Math.floor(number),!(number>=0&&119>=number))throw new RangeError(\"The control change number must be between 0 and 119.\");for(var cc in wm.MIDI_CONTROL_CHANGE_MESSAGES)if(wm.MIDI_CONTROL_CHANGE_MESSAGES.hasOwnProperty(cc)&&number===wm.MIDI_CONTROL_CHANGE_MESSAGES[cc])return cc;return void 0},Input.prototype.getChannelModeByNumber=function(number){if(number=Math.floor(number),!(number>=120&&status<=127))throw new RangeError(\"The control change number must be between 120 and 127.\");for(var cm in wm.MIDI_CHANNEL_MODE_MESSAGES)if(wm.MIDI_CHANNEL_MODE_MESSAGES.hasOwnProperty(cm)&&number===wm.MIDI_CHANNEL_MODE_MESSAGES[cm])return cm},Input.prototype._parseSystemEvent=function(e){var command=e.data[0],event={target:this,data:e.data,timestamp:e.timeStamp};command===wm.MIDI_SYSTEM_MESSAGES.sysex?event.type=\"sysex\":command===wm.MIDI_SYSTEM_MESSAGES.timecode?event.type=\"timecode\":command===wm.MIDI_SYSTEM_MESSAGES.songposition?event.type=\"songposition\":command===wm.MIDI_SYSTEM_MESSAGES.songselect?(event.type=\"songselect\",event.song=e.data[1]):command===wm.MIDI_SYSTEM_MESSAGES.tuningrequest?event.type=\"tuningrequest\":command===wm.MIDI_SYSTEM_MESSAGES.clock?event.type=\"clock\":command===wm.MIDI_SYSTEM_MESSAGES.start?event.type=\"start\":command===wm.MIDI_SYSTEM_MESSAGES[\"continue\"]?event.type=\"continue\":command===wm.MIDI_SYSTEM_MESSAGES.stop?event.type=\"stop\":command===wm.MIDI_SYSTEM_MESSAGES.activesensing?event.type=\"activesensing\":command===wm.MIDI_SYSTEM_MESSAGES.reset?event.type=\"reset\":event.type=\"unknownsystemmessage\",this._userHandlers.system[event.type]&&this._userHandlers.system[event.type].forEach(function(callback){callback(event)})},Output.prototype.send=function(status,data,timestamp){if(!(status>=128&&255>=status))throw new RangeError(\"The status byte must be an integer between 128 (0x80) and 255 (0xFF).\");void 0===data&&(data=[]),Array.isArray(data)||(data=[data]);var message=[];return data.forEach(function(item,index){var parsed=Math.floor(item);if(!(parsed>=0&&255>=parsed))throw new RangeError(\"Data bytes must be integers between 0 (0x00) and 255 (0xFF).\");message.push(parsed)}),this._midiOutput.send([status].concat(message),parseFloat(timestamp)||0),this},Output.prototype.sendSysex=function(manufacturer,data,options){if(!wm.sysexEnabled)throw new Error(\"Sysex message support must first be activated.\");return options=options||{},manufacturer=[].concat(manufacturer),data.forEach(function(item){if(0>item||item>127)throw new RangeError(\"The data bytes of a sysex message must be integers between 0 (0x00) and 127 (0x7F).\")}),data=manufacturer.concat(data,wm.MIDI_SYSTEM_MESSAGES.sysexend),this.send(wm.MIDI_SYSTEM_MESSAGES.sysex,data,this._parseTimeParameter(options.time)),this},Output.prototype.sendTimecodeQuarterFrame=function(value,options){return options=options||{},this.send(wm.MIDI_SYSTEM_MESSAGES.timecode,value,this._parseTimeParameter(options.time)),this},Output.prototype.sendSongPosition=function(value,options){value=Math.floor(value)||0,options=options||{};var msb=value>>7&127,lsb=127&value;return this.send(wm.MIDI_SYSTEM_MESSAGES.songposition,[msb,lsb],this._parseTimeParameter(options.time)),this},Output.prototype.sendSongSelect=function(value,options){if(value=Math.floor(value),options=options||{},!(value>=0&&127>=value))throw new RangeError(\"The song number must be between 0 and 127.\");return this.send(wm.MIDI_SYSTEM_MESSAGES.songselect,[value],this._parseTimeParameter(options.time)),this},Output.prototype.sendTuningRequest=function(options){return options=options||{},this.send(wm.MIDI_SYSTEM_MESSAGES.tuningrequest,void 0,this._parseTimeParameter(options.time)),this},Output.prototype.sendClock=function(options){return options=options||{},this.send(wm.MIDI_SYSTEM_MESSAGES.clock,void 0,this._parseTimeParameter(options.time)),this},Output.prototype.sendStart=function(options){return options=options||{},this.send(wm.MIDI_SYSTEM_MESSAGES.start,void 0,this._parseTimeParameter(options.time)),this},Output.prototype.sendContinue=function(options){return options=options||{},this.send(wm.MIDI_SYSTEM_MESSAGES[\"continue\"],void 0,this._parseTimeParameter(options.time)),this},Output.prototype.sendStop=function(options){return options=options||{},this.send(wm.MIDI_SYSTEM_MESSAGES.stop,void 0,this._parseTimeParameter(options.time)),this},Output.prototype.sendActiveSensing=function(options){return options=options||{},this.send(wm.MIDI_SYSTEM_MESSAGES.activesensing,[],this._parseTimeParameter(options.time)),this},Output.prototype.sendReset=function(options){return options=options||{},this.send(wm.MIDI_SYSTEM_MESSAGES.reset,void 0,this._parseTimeParameter(options.time)),this},Output.prototype.stopNote=function(note,channel,options){if(\"all\"===note)return this.sendChannelMode(\"allnotesoff\",0,channel,options);var nVelocity=64;return options=options||{},options.rawVelocity?!isNaN(options.velocity)&&options.velocity>=0&&options.velocity<=127&&(nVelocity=options.velocity):!isNaN(options.velocity)&&options.velocity>=0&&options.velocity<=1&&(nVelocity=127*options.velocity),this._convertNoteToArray(note).forEach(function(item){wm.toMIDIChannels(channel).forEach(function(ch){this.send((wm.MIDI_CHANNEL_MESSAGES.noteoff<<4)+(ch-1),[item,Math.round(nVelocity)],this._parseTimeParameter(options.time))}.bind(this))}.bind(this)),this},Output.prototype.playNote=function(note,channel,options){var nVelocity=64;if(options=options||{},options.rawVelocity?!isNaN(options.velocity)&&options.velocity>=0&&options.velocity<=127&&(nVelocity=options.velocity):!isNaN(options.velocity)&&options.velocity>=0&&options.velocity<=1&&(nVelocity=127*options.velocity),options.time=this._parseTimeParameter(options.time),this._convertNoteToArray(note).forEach(function(item){wm.toMIDIChannels(channel).forEach(function(ch){this.send((wm.MIDI_CHANNEL_MESSAGES.noteon<<4)+(ch-1),[item,Math.round(nVelocity)],options.time)}.bind(this))}.bind(this)),!isNaN(options.duration)){options.duration<=0&&(options.duration=0);var nRelease=64;options.rawVelocity?!isNaN(options.release)&&options.release>=0&&options.release<=127&&(nRelease=options.release):!isNaN(options.release)&&options.release>=0&&options.release<=1&&(nRelease=127*options.release),this._convertNoteToArray(note).forEach(function(item){wm.toMIDIChannels(channel).forEach(function(ch){this.send((wm.MIDI_CHANNEL_MESSAGES.noteoff<<4)+(ch-1),[item,Math.round(nRelease)],(options.time||wm.time)+options.duration)}.bind(this))}.bind(this))}return this},Output.prototype.sendKeyAftertouch=function(note,channel,pressure,options){var that=this;if(options=options||{},1>channel||channel>16)throw new RangeError(\"The channel must be between 1 and 16.\");(isNaN(pressure)||0>pressure||pressure>1)&&(pressure=.5);var nPressure=Math.round(127*pressure);return this._convertNoteToArray(note).forEach(function(item){wm.toMIDIChannels(channel).forEach(function(ch){that.send((wm.MIDI_CHANNEL_MESSAGES.keyaftertouch<<4)+(ch-1),[item,nPressure],that._parseTimeParameter(options.time))})}),this},Output.prototype.sendControlChange=function(controller,value,channel,options){if(options=options||{},\"string\"==typeof controller){if(controller=wm.MIDI_CONTROL_CHANGE_MESSAGES[controller],!controller)throw new TypeError(\"Invalid controller name.\")}else if(controller=Math.floor(controller),!(controller>=0&&119>=controller))throw new RangeError(\"Controller numbers must be between 0 and 119.\");if(value=Math.floor(value)||0,!(value>=0&&127>=value))throw new RangeError(\"Controller value must be between 0 and 127.\");return wm.toMIDIChannels(channel).forEach(function(ch){this.send((wm.MIDI_CHANNEL_MESSAGES.controlchange<<4)+(ch-1),[controller,value],this._parseTimeParameter(options.time))}.bind(this)),this},Output.prototype._selectRegisteredParameter=function(parameter,channel,time){var that=this;if(parameter[0]=Math.floor(parameter[0]),!(parameter[0]>=0&¶meter[0]<=127))throw new RangeError(\"The control65 value must be between 0 and 127\");if(parameter[1]=Math.floor(parameter[1]),!(parameter[1]>=0&¶meter[1]<=127))throw new RangeError(\"The control64 value must be between 0 and 127\");return wm.toMIDIChannels(channel).forEach(function(ch){that.sendControlChange(101,parameter[0],channel,{time:time}),that.sendControlChange(100,parameter[1],channel,{time:time})}),this},Output.prototype._selectNonRegisteredParameter=function(parameter,channel,time){var that=this;if(parameter[0]=Math.floor(parameter[0]),!(parameter[0]>=0&¶meter[0]<=127))throw new RangeError(\"The control63 value must be between 0 and 127\");if(parameter[1]=Math.floor(parameter[1]),!(parameter[1]>=0&¶meter[1]<=127))throw new RangeError(\"The control62 value must be between 0 and 127\");return wm.toMIDIChannels(channel).forEach(function(ch){that.sendControlChange(99,parameter[0],channel,{time:time}),that.sendControlChange(98,parameter[1],channel,{time:time})}),this},Output.prototype._setCurrentRegisteredParameter=function(data,channel,time){var that=this;if(data=[].concat(data),data[0]=Math.floor(data[0]),!(data[0]>=0&&data[0]<=127))throw new RangeError(\"The msb value must be between 0 and 127\");return wm.toMIDIChannels(channel).forEach(function(ch){that.sendControlChange(6,data[0],channel,{time:time})}),data[1]=Math.floor(data[1]),data[1]>=0&&data[1]<=127&&wm.toMIDIChannels(channel).forEach(function(ch){that.sendControlChange(38,data[1],channel,{time:time})}),this},Output.prototype._deselectRegisteredParameter=function(channel,time){var that=this;return wm.toMIDIChannels(channel).forEach(function(ch){that.sendControlChange(101,127,channel,{time:time}),that.sendControlChange(100,127,channel,{time:time})}),this},Output.prototype.setRegisteredParameter=function(parameter,data,channel,options){var that=this;if(options=options||{},!Array.isArray(parameter)){if(!wm.MIDI_REGISTERED_PARAMETER[parameter])throw new Error(\"The specified parameter is not available.\");parameter=wm.MIDI_REGISTERED_PARAMETER[parameter]}return wm.toMIDIChannels(channel).forEach(function(ch){that._selectRegisteredParameter(parameter,channel,options.time),that._setCurrentRegisteredParameter(data,channel,options.time),that._deselectRegisteredParameter(channel,options.time)}),this},Output.prototype.setNonRegisteredParameter=function(parameter,data,channel,options){var that=this;if(options=options||{},!(parameter[0]>=0&¶meter[0]<=127&¶meter[1]>=0&¶meter[1]<=127))throw new Error(\"Position 0 and 1 of the 2-position parameter array must both be between 0 and 127.\");return data=[].concat(data),wm.toMIDIChannels(channel).forEach(function(ch){that._selectNonRegisteredParameter(parameter,channel,options.time),that._setCurrentRegisteredParameter(data,channel,options.time),that._deselectRegisteredParameter(channel,options.time)}),this},Output.prototype.incrementRegisteredParameter=function(parameter,channel,options){var that=this;if(options=options||{},!Array.isArray(parameter)){if(!wm.MIDI_REGISTERED_PARAMETER[parameter])throw new Error(\"The specified parameter is not available.\");parameter=wm.MIDI_REGISTERED_PARAMETER[parameter]}return wm.toMIDIChannels(channel).forEach(function(ch){that._selectRegisteredParameter(parameter,channel,options.time),that.sendControlChange(96,0,channel,{time:options.time}),that._deselectRegisteredParameter(channel,options.time)}),this},Output.prototype.decrementRegisteredParameter=function(parameter,channel,options){if(options=options||{},!Array.isArray(parameter)){if(!wm.MIDI_REGISTERED_PARAMETER[parameter])throw new TypeError(\"The specified parameter is not available.\");parameter=wm.MIDI_REGISTERED_PARAMETER[parameter]}return wm.toMIDIChannels(channel).forEach(function(ch){this._selectRegisteredParameter(parameter,channel,options.time),this.sendControlChange(97,0,channel,{time:options.time}),this._deselectRegisteredParameter(channel,options.time)}.bind(this)),this},Output.prototype.setPitchBendRange=function(semitones,cents,channel,options){var that=this;if(options=options||{},semitones=Math.floor(semitones)||0,!(semitones>=0&&127>=semitones))throw new RangeError(\"The semitones value must be between 0 and 127\");if(cents=Math.floor(cents)||0,!(cents>=0&&127>=cents))throw new RangeError(\"The cents value must be between 0 and 127\");return wm.toMIDIChannels(channel).forEach(function(ch){that.setRegisteredParameter(\"pitchbendrange\",[semitones,cents],channel,{time:options.time})}),this},Output.prototype.setModulationRange=function(semitones,cents,channel,options){var that=this;if(options=options||{},semitones=Math.floor(semitones)||0,!(semitones>=0&&127>=semitones))throw new RangeError(\"The semitones value must be between 0 and 127\");if(cents=Math.floor(cents)||0,!(cents>=0&&127>=cents))throw new RangeError(\"The cents value must be between 0 and 127\");return wm.toMIDIChannels(channel).forEach(function(ch){that.setRegisteredParameter(\"modulationrange\",[semitones,cents],channel,{time:options.time})}),this},Output.prototype.setMasterTuning=function(value,channel,options){var that=this;if(options=options||{},value=parseFloat(value)||0,-65>=value||value>=64)throw new RangeError(\"The value must be a decimal number larger than -65 and smaller than 64.\");var coarse=Math.floor(value)+64,fine=value-Math.floor(value);fine=Math.round((fine+1)/2*16383);var msb=fine>>7&127,lsb=127&fine;return wm.toMIDIChannels(channel).forEach(function(ch){that.setRegisteredParameter(\"channelcoarsetuning\",coarse,channel,{time:options.time}),that.setRegisteredParameter(\"channelfinetuning\",[msb,lsb],channel,{time:options.time})}),this},Output.prototype.setTuningProgram=function(value,channel,options){var that=this;if(options=options||{},value=Math.floor(value),!(value>=0&&127>=value))throw new RangeError(\"The program value must be between 0 and 127\");return wm.toMIDIChannels(channel).forEach(function(ch){that.setRegisteredParameter(\"tuningprogram\",value,channel,{time:options.time})}),this},Output.prototype.setTuningBank=function(value,channel,options){var that=this;if(options=options||{},value=Math.floor(value)||0,!(value>=0&&127>=value))throw new RangeError(\"The bank value must be between 0 and 127\");return wm.toMIDIChannels(channel).forEach(function(ch){that.setRegisteredParameter(\"tuningbank\",value,channel,{time:options.time})}),this},Output.prototype.sendChannelMode=function(command,value,channel,options){if(options=options||{},\"string\"==typeof command){if(command=wm.MIDI_CHANNEL_MODE_MESSAGES[command],!command)throw new TypeError(\"Invalid channel mode message name.\")}else if(command=Math.floor(command),!(command>=120&&127>=command))throw new RangeError(\"Channel mode numerical identifiers must be between 120 and 127.\");if(value=Math.floor(value)||0,0>value||value>127)throw new RangeError(\"Value must be an integer between 0 and 127.\");return wm.toMIDIChannels(channel).forEach(function(ch){this.send((wm.MIDI_CHANNEL_MESSAGES.channelmode<<4)+(ch-1),[command,value],this._parseTimeParameter(options.time))}.bind(this)),this},Output.prototype.sendProgramChange=function(program,channel,options){\nvar that=this;if(options=options||{},program=Math.floor(program),isNaN(program)||0>program||program>127)throw new RangeError(\"Program numbers must be between 0 and 127.\");return wm.toMIDIChannels(channel).forEach(function(ch){that.send((wm.MIDI_CHANNEL_MESSAGES.programchange<<4)+(ch-1),[program],that._parseTimeParameter(options.time))}),this},Output.prototype.sendChannelAftertouch=function(pressure,channel,options){var that=this;options=options||{},pressure=parseFloat(pressure),(isNaN(pressure)||0>pressure||pressure>1)&&(pressure=.5);var nPressure=Math.round(127*pressure);return wm.toMIDIChannels(channel).forEach(function(ch){that.send((wm.MIDI_CHANNEL_MESSAGES.channelaftertouch<<4)+(ch-1),[nPressure],that._parseTimeParameter(options.time))}),this},Output.prototype.sendPitchBend=function(bend,channel,options){var that=this;if(options=options||{},isNaN(bend)||-1>bend||bend>1)throw new RangeError(\"Pitch bend value must be between -1 and 1.\");var nLevel=Math.round((bend+1)/2*16383),msb=nLevel>>7&127,lsb=127&nLevel;return wm.toMIDIChannels(channel).forEach(function(ch){that.send((wm.MIDI_CHANNEL_MESSAGES.pitchbend<<4)+(ch-1),[lsb,msb],that._parseTimeParameter(options.time))}),this},Output.prototype._parseTimeParameter=function(time){var parsed,value;return\"string\"==typeof time&&\"+\"===time.substring(0,1)?(parsed=parseFloat(time),parsed&&parsed>0&&(value=wm.time+parsed)):(parsed=parseFloat(time),parsed>wm.time&&(value=parsed)),value},Output.prototype._convertNoteToArray=function(note){var notes=[];return Array.isArray(note)||(note=[note]),note.forEach(function(item){notes.push(wm.guessNoteNumber(item))}),notes}, true?!(__WEBPACK_AMD_DEFINE_ARRAY__ = [], __WEBPACK_AMD_DEFINE_RESULT__ = (function(){return wm}).apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__),\n\t\t\t\t__WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__)):undefined}(this);\n\n//# sourceURL=webpack:///./node_modules/webmidi/webmidi.min.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/webpack/buildin/global.js":
|
|
/*!***********************************!*\
|
|
!*** (webpack)/buildin/global.js ***!
|
|
\***********************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports) {
|
|
|
|
eval("var g;\n\n// This works in non-strict mode\ng = (function() {\n\treturn this;\n})();\n\ntry {\n\t// This works if eval is allowed (see CSP)\n\tg = g || new Function(\"return this\")();\n} catch (e) {\n\t// This works if the window reference is available\n\tif (typeof window === \"object\") g = window;\n}\n\n// g can still be undefined, but nothing to do about it...\n// We return undefined, instead of nothing here, so it's\n// easier to handle this case. if(!global) { ...}\n\nmodule.exports = g;\n\n\n//# sourceURL=webpack:///(webpack)/buildin/global.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/which-boxed-primitive/index.js":
|
|
/*!*****************************************************!*\
|
|
!*** ./node_modules/which-boxed-primitive/index.js ***!
|
|
\*****************************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\nvar isString = __webpack_require__(/*! is-string */ \"./node_modules/is-string/index.js\");\nvar isNumber = __webpack_require__(/*! is-number-object */ \"./node_modules/is-number-object/index.js\");\nvar isBoolean = __webpack_require__(/*! is-boolean-object */ \"./node_modules/is-boolean-object/index.js\");\nvar isSymbol = __webpack_require__(/*! is-symbol */ \"./node_modules/is-symbol/index.js\");\nvar isBigInt = __webpack_require__(/*! is-bigint */ \"./node_modules/is-bigint/index.js\");\n\n// eslint-disable-next-line consistent-return\nmodule.exports = function whichBoxedPrimitive(value) {\n\t// eslint-disable-next-line eqeqeq\n\tif (value == null || (typeof value !== 'object' && typeof value !== 'function')) {\n\t\treturn null;\n\t}\n\tif (isString(value)) {\n\t\treturn 'String';\n\t}\n\tif (isNumber(value)) {\n\t\treturn 'Number';\n\t}\n\tif (isBoolean(value)) {\n\t\treturn 'Boolean';\n\t}\n\tif (isSymbol(value)) {\n\t\treturn 'Symbol';\n\t}\n\tif (isBigInt(value)) {\n\t\treturn 'BigInt';\n\t}\n};\n\n\n//# sourceURL=webpack:///./node_modules/which-boxed-primitive/index.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/which-collection/index.js":
|
|
/*!************************************************!*\
|
|
!*** ./node_modules/which-collection/index.js ***!
|
|
\************************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\n\nvar isMap = __webpack_require__(/*! is-map */ \"./node_modules/is-map/index.js\");\nvar isSet = __webpack_require__(/*! is-set */ \"./node_modules/is-set/index.js\");\nvar isWeakMap = __webpack_require__(/*! is-weakmap */ \"./node_modules/is-weakmap/index.js\");\nvar isWeakSet = __webpack_require__(/*! is-weakset */ \"./node_modules/is-weakset/index.js\");\n\nmodule.exports = function whichCollection(value) {\n\tif (value && typeof value === 'object') {\n\t\tif (isMap(value)) {\n\t\t\treturn 'Map';\n\t\t}\n\t\tif (isSet(value)) {\n\t\t\treturn 'Set';\n\t\t}\n\t\tif (isWeakMap(value)) {\n\t\t\treturn 'WeakMap';\n\t\t}\n\t\tif (isWeakSet(value)) {\n\t\t\treturn 'WeakSet';\n\t\t}\n\t}\n\treturn false;\n};\n\n\n//# sourceURL=webpack:///./node_modules/which-collection/index.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./node_modules/which-typed-array/index.js":
|
|
/*!*************************************************!*\
|
|
!*** ./node_modules/which-typed-array/index.js ***!
|
|
\*************************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("/* WEBPACK VAR INJECTION */(function(global) {\n\nvar forEach = __webpack_require__(/*! foreach */ \"./node_modules/foreach/index.js\");\nvar availableTypedArrays = __webpack_require__(/*! available-typed-arrays */ \"./node_modules/available-typed-arrays/index.js\");\nvar callBound = __webpack_require__(/*! es-abstract/helpers/callBound */ \"./node_modules/es-abstract/helpers/callBound.js\");\n\nvar $toString = callBound('Object.prototype.toString');\nvar hasSymbols = __webpack_require__(/*! has-symbols */ \"./node_modules/has-symbols/index.js\")();\nvar hasToStringTag = hasSymbols && typeof Symbol.toStringTag === 'symbol';\n\nvar typedArrays = availableTypedArrays();\n\nvar $slice = callBound('String.prototype.slice');\nvar toStrTags = {};\nvar gOPD = __webpack_require__(/*! es-abstract/helpers/getOwnPropertyDescriptor */ \"./node_modules/es-abstract/helpers/getOwnPropertyDescriptor.js\");\nvar getPrototypeOf = Object.getPrototypeOf; // require('getprototypeof');\nif (hasToStringTag && gOPD && getPrototypeOf) {\n\tforEach(typedArrays, function (typedArray) {\n\t\tif (typeof global[typedArray] === 'function') {\n\t\t\tvar arr = new global[typedArray]();\n\t\t\tif (!(Symbol.toStringTag in arr)) {\n\t\t\t\tthrow new EvalError('this engine has support for Symbol.toStringTag, but ' + typedArray + ' does not have the property! Please report this.');\n\t\t\t}\n\t\t\tvar proto = getPrototypeOf(arr);\n\t\t\tvar descriptor = gOPD(proto, Symbol.toStringTag);\n\t\t\tif (!descriptor) {\n\t\t\t\tvar superProto = getPrototypeOf(proto);\n\t\t\t\tdescriptor = gOPD(superProto, Symbol.toStringTag);\n\t\t\t}\n\t\t\ttoStrTags[typedArray] = descriptor.get;\n\t\t}\n\t});\n}\n\nvar tryTypedArrays = function tryAllTypedArrays(value) {\n\tvar foundName = false;\n\tforEach(toStrTags, function (getter, typedArray) {\n\t\tif (!foundName) {\n\t\t\ttry {\n\t\t\t\tvar name = getter.call(value);\n\t\t\t\tif (name === typedArray) {\n\t\t\t\t\tfoundName = name;\n\t\t\t\t}\n\t\t\t} catch (e) {}\n\t\t}\n\t});\n\treturn foundName;\n};\n\nvar isTypedArray = __webpack_require__(/*! is-typed-array */ \"./node_modules/is-typed-array/index.js\");\n\nmodule.exports = function whichTypedArray(value) {\n\tif (!isTypedArray(value)) { return false; }\n\tif (!hasToStringTag) { return $slice($toString(value), 8, -1); }\n\treturn tryTypedArrays(value);\n};\n\n/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./../webpack/buildin/global.js */ \"./node_modules/webpack/buildin/global.js\")))\n\n//# sourceURL=webpack:///./node_modules/which-typed-array/index.js?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./src/gui/component/audio-node.scss":
|
|
/*!*******************************************!*\
|
|
!*** ./src/gui/component/audio-node.scss ***!
|
|
\*******************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
eval("\n var result = __webpack_require__(/*! !../../../node_modules/css-loader/dist/cjs.js!../../../node_modules/sass-loader/dist/cjs.js??ref--5-2!./audio-node.scss */ \"./node_modules/css-loader/dist/cjs.js!./node_modules/sass-loader/dist/cjs.js?!./src/gui/component/audio-node.scss\");\n\n if (typeof result === \"string\") {\n module.exports = result;\n } else {\n module.exports = result.toString();\n }\n \n\n//# sourceURL=webpack:///./src/gui/component/audio-node.scss?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./src/gui/component/audio-node.ts":
|
|
/*!*****************************************!*\
|
|
!*** ./src/gui/component/audio-node.ts ***!
|
|
\*****************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.createElement = exports.ToneAudioNodeElement = void 0;\nconst lit_element_1 = __webpack_require__(/*! lit-element */ \"./node_modules/lit-element/lit-element.js\");\n__webpack_require__(/*! ../value/number */ \"./src/gui/value/number.ts\");\n__webpack_require__(/*! ../value/string */ \"./src/gui/value/string.ts\");\n__webpack_require__(/*! ../value/array */ \"./src/gui/value/array.ts\");\n__webpack_require__(/*! ../value/boolean */ \"./src/gui/value/boolean.ts\");\n__webpack_require__(/*! ../vis/visualizer */ \"./src/gui/vis/visualizer.ts\");\nconst style = __webpack_require__(/*! ./audio-node.scss */ \"./src/gui/component/audio-node.scss\");\n__webpack_require__(/*! @material/mwc-icon */ \"./node_modules/@material/mwc-icon/mwc-icon.js\");\nlet ToneAudioNodeElement = class ToneAudioNodeElement extends lit_element_1.LitElement {\n constructor() {\n super(...arguments);\n /**\n * If the node is open or closed\n */\n this.open = true;\n }\n pathToObject(path, value) {\n const obj = {};\n let subValue = obj;\n path.forEach((prop, index) => {\n if (index === path.length - 1) {\n subValue[prop] = value;\n }\n else {\n subValue[prop] = {};\n subValue = subValue[prop];\n }\n });\n return obj;\n }\n pathToValue(path, obj) {\n let subValue = obj;\n let retValue = undefined;\n path.forEach((prop, index) => {\n if (index === path.length - 1) {\n retValue = subValue[prop];\n }\n else {\n subValue = subValue[prop];\n }\n });\n return retValue;\n }\n bind(tone) {\n return __awaiter(this, void 0, void 0, function* () {\n this.tone = tone;\n yield this.requestUpdate();\n // also bind all of the children nodes\n this.shadowRoot\n .querySelectorAll(\"tone-visualizer\")\n .forEach((vis) => {\n vis.bind(this.tone);\n });\n });\n }\n setValue(path, detail) {\n if (this.tone) {\n const currentValue = this.tone.get();\n try {\n this.tone.set(this.pathToObject(path, detail.value));\n }\n catch (e) {\n const previousValue = this.pathToValue(path, currentValue);\n this.tone.set(this.pathToObject(path, previousValue));\n detail.reject(previousValue);\n }\n this.requestUpdate();\n }\n }\n renderValue(name, values, path) {\n const value = values[name];\n if (typeof value === \"number\") {\n return lit_element_1.html `\n\t\t\t\t<tone-number\n\t\t\t\t\tclass=\"value\"\n\t\t\t\t\t@value=${(e) => this.setValue(path, e.detail)}\n\t\t\t\t\tname=\"${name}\"\n\t\t\t\t\tvalue=${value}\n\t\t\t\t></tone-number>\n\t\t\t`;\n }\n else if (typeof value === \"string\") {\n return lit_element_1.html `\n\t\t\t\t<tone-string\n\t\t\t\t\tclass=\"value\"\n\t\t\t\t\t@value=${(e) => this.setValue(path, e.detail)}\n\t\t\t\t\tname=\"${name}\"\n\t\t\t\t\tvalue=\"${value}\"\n\t\t\t\t></tone-string>\n\t\t\t`;\n }\n else if (typeof value === \"boolean\") {\n return lit_element_1.html `\n\t\t\t\t<tone-boolean\n\t\t\t\t\tclass=\"value\"\n\t\t\t\t\t@value=${(e) => this.setValue(path, e.detail)}\n\t\t\t\t\tname=\"${name}\"\n\t\t\t\t\t?value=${value}\n\t\t\t\t></tone-boolean>\n\t\t\t`;\n }\n else if (Array.isArray(value)) {\n return lit_element_1.html `\n\t\t\t\t<tone-array\n\t\t\t\t\tclass=\"value\"\n\t\t\t\t\t@value=${(e) => this.setValue(path, e.detail)}\n\t\t\t\t\tname=\"${name}\"\n\t\t\t\t\tvalue=${JSON.stringify(value)}\n\t\t\t\t></tone-array>\n\t\t\t`;\n }\n else if (typeof value === \"object\") {\n return lit_element_1.html `\n\t\t\t\t<details\n\t\t\t\t\tclass=\"sub-value\"\n\t\t\t\t\t@toggle=${(e) => (e.target.querySelector(\"mwc-icon\").textContent = e\n .target.open\n ? \"arrow_drop_down\"\n : \"arrow_right\")}\n\t\t\t\t>\n\t\t\t\t\t<summary>\n\t\t\t\t\t\t<mwc-icon>\n\t\t\t\t\t\t\tarrow_right\n\t\t\t\t\t\t</mwc-icon>\n\t\t\t\t\t\t${name}\n\t\t\t\t\t</summary>\n\t\t\t\t\t<div class=\"sub-values\">\n\t\t\t\t\t\t${this.renderValues(value, [...path])}\n\t\t\t\t\t</div>\n\t\t\t\t</details>\n\t\t\t`;\n }\n }\n toneObjFromPath(path) {\n let tone = this.tone;\n path.forEach((seg) => {\n tone = tone[seg];\n });\n if (tone) {\n return tone.get();\n }\n else {\n return {};\n }\n }\n sortValues(values) {\n const ret = {};\n const keys = Object.keys(values);\n function isObject(value) {\n return typeof value === \"object\" && !Array.isArray(value);\n }\n // first put in all of the non-objects\n keys.sort().forEach((key) => {\n const value = values[key];\n if (!isObject(value)) {\n ret[key] = value;\n }\n });\n // put in all of the objects\n keys.sort().forEach((key) => {\n const value = values[key];\n if (isObject(value) && Object.keys(value).length) {\n ret[key] = value;\n }\n });\n return ret;\n }\n renderValues(values, path) {\n values = this.sortValues(values);\n return lit_element_1.html `\n\t\t\t<tone-visualizer\n\t\t\t\tpath=${JSON.stringify(path)}\n\t\t\t\tvalues=${JSON.stringify(this.toneObjFromPath(path))}\n\t\t\t>\n\t\t\t</tone-visualizer>\n\t\t\t${Object.keys(values).map((name) => lit_element_1.html `\n\t\t\t\t\t${this.renderValue(name, values, [...path, name])}\n\t\t\t\t`)}\n\t\t`;\n }\n static get styles() {\n return lit_element_1.css `\n\t\t\t${lit_element_1.unsafeCSS(style)}\n\t\t`;\n }\n render() {\n if (this.tone) {\n return lit_element_1.html `\n\t\t\t\t<div id=\"container\">\n\t\t\t\t\t<details\n\t\t\t\t\t\t?open=${this.open}\n\t\t\t\t\t\t@toggle=${(e) => (this.open = e.target.open)}\n\t\t\t\t\t>\n\t\t\t\t\t\t<summary id=\"title\">\n\t\t\t\t\t\t\t<mwc-icon>\n\t\t\t\t\t\t\t\t${this.open\n ? \"keyboard_arrow_down\"\n : \"keyboard_arrow_right\"}\n\t\t\t\t\t\t\t</mwc-icon>\n\t\t\t\t\t\t\t<span>\n\t\t\t\t\t\t\t\t${this.name}\n\t\t\t\t\t\t\t</span>\n\t\t\t\t\t\t</summary>\n\t\t\t\t\t\t${this.renderValues(this.tone.get(), [])}\n\t\t\t\t\t\t<details id=\"json\">\n\t\t\t\t\t\t\t<summary> <mwc-icon>code</mwc-icon> </summary>\n\t\t\t\t\t\t\t<pre>\n${JSON.stringify(this.tone.get(), undefined, \"\\t\")}</pre\n\t\t\t\t\t\t\t>\n\t\t\t\t\t\t</details>\n\t\t\t\t\t</details>\n\t\t\t\t</div>\n\t\t\t`;\n }\n else {\n return lit_element_1.html `\n\t\t\t\t<div id=\"container\">\n\t\t\t\t\t<h4>${this.name}</h4>\n\t\t\t\t\t<div>Set a Tone.js object with 'bind'</div>\n\t\t\t\t</div>\n\t\t\t`;\n }\n }\n};\n__decorate([\n lit_element_1.property({ type: String })\n], ToneAudioNodeElement.prototype, \"name\", void 0);\n__decorate([\n lit_element_1.property({ type: Boolean })\n], ToneAudioNodeElement.prototype, \"open\", void 0);\nToneAudioNodeElement = __decorate([\n lit_element_1.customElement(\"tone-audio-node\")\n], ToneAudioNodeElement);\nexports.ToneAudioNodeElement = ToneAudioNodeElement;\n/**\n * Create an audio node element\n */\nfunction createElement({ tone, name = tone.toString(), parent, open = false, }) {\n const element = document.createElement(\"tone-audio-node\");\n element.bind(tone);\n element.name = name;\n element.open = open;\n if (parent) {\n parent.appendChild(element);\n }\n return element;\n}\nexports.createElement = createElement;\n\n\n//# sourceURL=webpack:///./src/gui/component/audio-node.ts?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./src/gui/component/drawer.scss":
|
|
/*!***************************************!*\
|
|
!*** ./src/gui/component/drawer.scss ***!
|
|
\***************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
eval("\n var result = __webpack_require__(/*! !../../../node_modules/css-loader/dist/cjs.js!../../../node_modules/sass-loader/dist/cjs.js??ref--5-2!./drawer.scss */ \"./node_modules/css-loader/dist/cjs.js!./node_modules/sass-loader/dist/cjs.js?!./src/gui/component/drawer.scss\");\n\n if (typeof result === \"string\") {\n module.exports = result;\n } else {\n module.exports = result.toString();\n }\n \n\n//# sourceURL=webpack:///./src/gui/component/drawer.scss?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./src/gui/component/drawer.ts":
|
|
/*!*************************************!*\
|
|
!*** ./src/gui/component/drawer.ts ***!
|
|
\*************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.createDrawer = exports.ToneDrawerElement = void 0;\nconst lit_element_1 = __webpack_require__(/*! lit-element */ \"./node_modules/lit-element/lit-element.js\");\nconst audio_node_1 = __webpack_require__(/*! ./audio-node */ \"./src/gui/component/audio-node.ts\");\nconst folder_1 = __webpack_require__(/*! ./folder */ \"./src/gui/component/folder.ts\");\nconst style = __webpack_require__(/*! ./drawer.scss */ \"./src/gui/component/drawer.scss\");\n__webpack_require__(/*! @material/mwc-icon */ \"./node_modules/@material/mwc-icon/mwc-icon.js\");\n/**\n * Collapsible element to add\n */\nlet ToneDrawerElement = class ToneDrawerElement extends lit_element_1.LitElement {\n constructor() {\n super(...arguments);\n /**\n * If the element is collapsed\n */\n this.open = true;\n /**\n * If the element is not visible on the page\n */\n this.hidden = false;\n }\n firstUpdated(props) {\n super.firstUpdated(props);\n document.body.addEventListener(\"keypress\", (e) => {\n if (e.key === \"H\") {\n this.hidden = !this.hidden;\n }\n });\n }\n static get styles() {\n return lit_element_1.css `\n\t\t\t${lit_element_1.unsafeCSS(style)}\n\t\t`;\n }\n /**\n * Add a Tone.js ToneAudioNode\n */\n add(options) {\n const element = audio_node_1.createElement(options);\n this.appendChild(element);\n return this;\n }\n /**\n * Create a folder with the given name\n */\n folder({ name, open }) {\n const element = folder_1.createFolder({ name, open });\n this.appendChild(element);\n return element;\n }\n render() {\n return lit_element_1.html `\n\t\t\t<div id=\"container\" ?open=${this.open} ?hidden=${this.hidden}>\n\t\t\t\t<details\n\t\t\t\t\t?open=${this.open}\n\t\t\t\t\t@toggle=${(e) => (this.open = e.target.open)}\n\t\t\t\t>\n\t\t\t\t\t<summary>\n\t\t\t\t\t\t<mwc-icon>\n\t\t\t\t\t\t\t${!this.open ? \"unfold_more\" : \"unfold_less\"}\n\t\t\t\t\t\t</mwc-icon>\n\t\t\t\t\t\t${this.open ? \"close\" : \"controls\"}\n\t\t\t\t\t</summary>\n\t\t\t\t\t<div id=\"scroll\">\n\t\t\t\t\t\t<div id=\"inner-scroll\">\n\t\t\t\t\t\t\t<slot></slot>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t</div>\n\t\t\t\t</details>\n\t\t\t</div>\n\t\t`;\n }\n};\n__decorate([\n lit_element_1.property({ type: Boolean })\n], ToneDrawerElement.prototype, \"open\", void 0);\n__decorate([\n lit_element_1.property({ type: Boolean })\n], ToneDrawerElement.prototype, \"hidden\", void 0);\nToneDrawerElement = __decorate([\n lit_element_1.customElement(\"tone-drawer\")\n], ToneDrawerElement);\nexports.ToneDrawerElement = ToneDrawerElement;\n/**\n * Create a collapsible drawer\n */\nfunction createDrawer({ parent = document.body, open = false, } = {}) {\n const element = document.createElement(\"tone-drawer\");\n if (parent) {\n parent.appendChild(element);\n }\n element.open = open;\n return element;\n}\nexports.createDrawer = createDrawer;\n\n\n//# sourceURL=webpack:///./src/gui/component/drawer.ts?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./src/gui/component/folder.scss":
|
|
/*!***************************************!*\
|
|
!*** ./src/gui/component/folder.scss ***!
|
|
\***************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
eval("\n var result = __webpack_require__(/*! !../../../node_modules/css-loader/dist/cjs.js!../../../node_modules/sass-loader/dist/cjs.js??ref--5-2!./folder.scss */ \"./node_modules/css-loader/dist/cjs.js!./node_modules/sass-loader/dist/cjs.js?!./src/gui/component/folder.scss\");\n\n if (typeof result === \"string\") {\n module.exports = result;\n } else {\n module.exports = result.toString();\n }\n \n\n//# sourceURL=webpack:///./src/gui/component/folder.scss?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./src/gui/component/folder.ts":
|
|
/*!*************************************!*\
|
|
!*** ./src/gui/component/folder.ts ***!
|
|
\*************************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.createFolder = exports.ToneFolderElement = void 0;\nconst lit_element_1 = __webpack_require__(/*! lit-element */ \"./node_modules/lit-element/lit-element.js\");\nconst audio_node_1 = __webpack_require__(/*! ./audio-node */ \"./src/gui/component/audio-node.ts\");\nconst style = __webpack_require__(/*! ./folder.scss */ \"./src/gui/component/folder.scss\");\n__webpack_require__(/*! @material/mwc-icon */ \"./node_modules/@material/mwc-icon/mwc-icon.js\");\n/**\n * A collapsible folder inside tone-drawer\n */\nlet ToneFolderElement = class ToneFolderElement extends lit_element_1.LitElement {\n constructor() {\n super(...arguments);\n /**\n * If it is open or collapsed\n */\n this.open = true;\n }\n static get styles() {\n return lit_element_1.css `\n\t\t\t${lit_element_1.unsafeCSS(style)}\n\t\t`;\n }\n /**\n * Add a Tone.js ToneAudioNode\n */\n add({ tone, name }) {\n const element = audio_node_1.createElement({\n tone,\n name,\n });\n this.appendChild(element);\n return this;\n }\n render() {\n return lit_element_1.html `\n\t\t\t<div id=\"container\" ?open=${this.open}>\n\t\t\t\t<details\n\t\t\t\t\t?open=${this.open}\n\t\t\t\t\t@toggle=${(e) => (this.open = e.target.open)}\n\t\t\t\t>\n\t\t\t\t\t<summary>\n\t\t\t\t\t\t<mwc-icon>\n\t\t\t\t\t\t\t${this.open\n ? \"keyboard_arrow_down\"\n : \"keyboard_arrow_right\"}\n\t\t\t\t\t\t</mwc-icon>\n\t\t\t\t\t\t<span>\n\t\t\t\t\t\t\t${this.name}\n\t\t\t\t\t\t</span>\n\t\t\t\t\t</summary>\n\t\t\t\t\t<div id=\"contents\">\n\t\t\t\t\t\t<slot></slot>\n\t\t\t\t\t</div>\n\t\t\t\t</details>\n\t\t\t</div>\n\t\t`;\n }\n};\n__decorate([\n lit_element_1.property({ type: Boolean })\n], ToneFolderElement.prototype, \"open\", void 0);\n__decorate([\n lit_element_1.property({ type: String })\n], ToneFolderElement.prototype, \"name\", void 0);\nToneFolderElement = __decorate([\n lit_element_1.customElement(\"tone-folder\")\n], ToneFolderElement);\nexports.ToneFolderElement = ToneFolderElement;\n/**\n * Create a folder with the given name\n */\nfunction createFolder({ name, parent, open = false, }) {\n const element = document.createElement(\"tone-folder\");\n element.name = name;\n element.open = open;\n if (parent) {\n parent.appendChild(element);\n }\n return element;\n}\nexports.createFolder = createFolder;\n\n\n//# sourceURL=webpack:///./src/gui/component/folder.ts?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./src/gui/index.ts":
|
|
/*!**************************!*\
|
|
!*** ./src/gui/index.ts ***!
|
|
\**************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.piano = exports.meter = exports.fft = exports.waveform = exports.folder = exports.drawer = exports.ui = void 0;\n__webpack_require__(/*! ./component/audio-node */ \"./src/gui/component/audio-node.ts\");\n__webpack_require__(/*! ./component/drawer */ \"./src/gui/component/drawer.ts\");\n__webpack_require__(/*! ./component/folder */ \"./src/gui/component/folder.ts\");\n__webpack_require__(/*! ./piano/piano */ \"./src/gui/piano/piano.ts\");\n__webpack_require__(/*! @material/mwc-icon */ \"./node_modules/@material/mwc-icon/mwc-icon.js\");\nconst audio_node_1 = __webpack_require__(/*! ./component/audio-node */ \"./src/gui/component/audio-node.ts\");\nconst drawer_1 = __webpack_require__(/*! ./component/drawer */ \"./src/gui/component/drawer.ts\");\nconst folder_1 = __webpack_require__(/*! ./component/folder */ \"./src/gui/component/folder.ts\");\nconst waveform_1 = __webpack_require__(/*! ./vis/waveform */ \"./src/gui/vis/waveform.ts\");\nconst fft_1 = __webpack_require__(/*! ./vis/fft */ \"./src/gui/vis/fft.ts\");\nconst meter_1 = __webpack_require__(/*! ./vis/meter */ \"./src/gui/vis/meter.ts\");\nconst piano_1 = __webpack_require__(/*! ./piano/piano */ \"./src/gui/piano/piano.ts\");\nvar drawer_2 = __webpack_require__(/*! ./component/drawer */ \"./src/gui/component/drawer.ts\");\nObject.defineProperty(exports, \"ToneDrawerElement\", { enumerable: true, get: function () { return drawer_2.ToneDrawerElement; } });\nvar folder_2 = __webpack_require__(/*! ./component/folder */ \"./src/gui/component/folder.ts\");\nObject.defineProperty(exports, \"ToneFolderElement\", { enumerable: true, get: function () { return folder_2.ToneFolderElement; } });\nvar audio_node_2 = __webpack_require__(/*! ./component/audio-node */ \"./src/gui/component/audio-node.ts\");\nObject.defineProperty(exports, \"ToneAudioNodeElement\", { enumerable: true, get: function () { return audio_node_2.ToneAudioNodeElement; } });\nexports.ui = audio_node_1.createElement;\nexports.drawer = drawer_1.createDrawer;\nexports.folder = folder_1.createFolder;\nexports.waveform = waveform_1.createWaveform;\nexports.fft = fft_1.createFFT;\nexports.meter = meter_1.createMeter;\nexports.piano = piano_1.createPiano;\n\n\n//# sourceURL=webpack:///./src/gui/index.ts?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./src/gui/piano/keyboard.ts":
|
|
/*!***********************************!*\
|
|
!*** ./src/gui/piano/keyboard.ts ***!
|
|
\***********************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.ToneKeyboard = void 0;\nconst lit_element_1 = __webpack_require__(/*! lit-element */ \"./node_modules/lit-element/lit-element.js\");\nconst AudioKeys = __webpack_require__(/*! audiokeys */ \"./node_modules/audiokeys/src/AudioKeys.js\");\n__webpack_require__(/*! ./octave */ \"./src/gui/piano/octave.ts\");\n__webpack_require__(/*! ./note */ \"./src/gui/piano/note.ts\");\nlet ToneKeyboard = class ToneKeyboard extends lit_element_1.LitElement {\n constructor() {\n super();\n this.rootoctave = 4;\n this.octaves = 4;\n this.polyphonic = false;\n this._computerKeyboard = new AudioKeys({ polyphony: Infinity });\n this._computerKeyboard.down((e) => {\n this.noteon(e.note);\n });\n this._computerKeyboard.up((e) => {\n this.noteoff(e.note);\n });\n }\n getNoteByTouchId(id) {\n const octaves = Array.from(this.shadowRoot.querySelectorAll(\"tone-keyboard-octave\"));\n const octave = octaves.find((o) => o.getNoteByTouchId(id));\n if (octave) {\n return octave.getNoteByTouchId(id);\n }\n }\n _touchmove(event) {\n Array.from(event.changedTouches).forEach((e) => {\n this.getNoteByTouchId(e.identifier);\n const activeNote = this.getNoteByTouchId(e.identifier);\n const element = this.shadowRoot.elementFromPoint(e.clientX, e.clientY);\n if (element && element.shadowRoot) {\n const note = element.shadowRoot.elementFromPoint(e.clientX, e.clientY);\n if (note && note.note && activeNote.note !== note.note) {\n activeNote.active = false;\n activeNote.touchid = -1;\n note.active = true;\n note.touchid = e.identifier;\n }\n }\n });\n }\n _touchend(event) {\n Array.from(event.changedTouches).forEach((e) => {\n this.getNoteByTouchId(e.identifier);\n const activeNote = this.getNoteByTouchId(e.identifier);\n if (activeNote && activeNote.active) {\n activeNote.active = false;\n activeNote.touchid = -1;\n }\n });\n }\n noteon(midi) {\n const octaveNumber = Math.floor(midi / 12);\n const toneOctave = this.shadowRoot.querySelector(`tone-keyboard-octave[octave=\"${octaveNumber}\"]`);\n if (toneOctave) {\n toneOctave.noteon(midi);\n }\n }\n noteoff(midi) {\n const octaveNumber = Math.floor(midi / 12);\n const toneOctave = this.shadowRoot.querySelector(`tone-keyboard-octave[octave=\"${octaveNumber}\"]`);\n if (toneOctave) {\n toneOctave.noteoff(midi);\n }\n }\n render() {\n const octaves = [];\n for (let i = this.rootoctave; i < this.rootoctave + this.octaves; i++) {\n octaves.push(i);\n }\n return lit_element_1.html `\n\t\t\t<style>\n\t\t\t\t#container {\n\t\t\t\t\tdisplay: flex;\n\t\t\t\t\tbackground-color: white;\n\t\t\t\t\theight: 80px;\n\t\t\t\t}\n\n\t\t\t\ttone-keyboard-octave {\n\t\t\t\t\tflex-grow: 1;\n\t\t\t\t}\n\t\t\t</style>\n\t\t\t<div\n\t\t\t\tid=\"container\"\n\t\t\t\t@touchmove=${this._touchmove.bind(this)}\n\t\t\t\t@touchend=${this._touchend.bind(this)}\n\t\t\t>\n\t\t\t\t${octaves.map((o) => lit_element_1.html `\n\t\t\t\t\t\t<tone-keyboard-octave\n\t\t\t\t\t\t\toctave=${o.toString()}\n\t\t\t\t\t\t></tone-keyboard-octave>\n\t\t\t\t\t`)}\n\t\t\t</div>\n\t\t`;\n }\n};\n__decorate([\n lit_element_1.property({ type: Number })\n], ToneKeyboard.prototype, \"rootoctave\", void 0);\n__decorate([\n lit_element_1.property({ type: Number })\n], ToneKeyboard.prototype, \"octaves\", void 0);\n__decorate([\n lit_element_1.property({ type: Boolean })\n], ToneKeyboard.prototype, \"polyphonic\", void 0);\nToneKeyboard = __decorate([\n lit_element_1.customElement(\"tone-keyboard\")\n], ToneKeyboard);\nexports.ToneKeyboard = ToneKeyboard;\n\n\n//# sourceURL=webpack:///./src/gui/piano/keyboard.ts?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./src/gui/piano/midi-in.ts":
|
|
/*!**********************************!*\
|
|
!*** ./src/gui/piano/midi-in.ts ***!
|
|
\**********************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.ToneMidiIn = void 0;\nconst lit_element_1 = __webpack_require__(/*! lit-element */ \"./node_modules/lit-element/lit-element.js\");\nconst WebMidi = __webpack_require__(/*! webmidi */ \"./node_modules/webmidi/webmidi.min.js\");\n// const WebMidi: import(\"webmidi\").WebMidi = require(\"webmidi\");\nlet ToneMidiIn = class ToneMidiIn extends lit_element_1.LitElement {\n constructor() {\n super();\n this._flashTimeout = -1;\n WebMidi.enable((e) => {\n if (!e) {\n WebMidi.addListener(\"connected\", (e) => {\n if (e.port.type === \"input\") {\n this.requestUpdate();\n }\n });\n WebMidi.addListener(\"disconnected\", (e) => {\n this.requestUpdate();\n });\n }\n });\n }\n _flash() {\n clearTimeout(this._flashTimeout);\n const light = this.shadowRoot.querySelector(\"#light\");\n light.classList.add(\"flash\");\n this._flashTimeout = setTimeout(() => light.classList.remove(\"flash\"), 100);\n }\n _connectMidi(event) {\n if (event.target.value === \"none\") {\n this.shadowRoot\n .querySelector(\"#light\")\n .classList.remove(\"connected\");\n return;\n }\n else {\n this.shadowRoot.querySelector(\"#light\").classList.add(\"connected\");\n }\n const input = WebMidi.getInputById(event.target.value);\n if (input) {\n input.addListener(\"noteon\", \"all\", (e) => {\n const name = `${e.note.name}${e.note.octave}`;\n const midi = e.note.number;\n this._flash();\n this.dispatchEvent(new CustomEvent(\"noteon\", {\n detail: {\n name,\n midi,\n velocity: e.velocity,\n },\n composed: true,\n bubbles: true,\n }));\n });\n input.addListener(\"noteoff\", \"all\", (e) => {\n const name = `${e.note.name}${e.note.octave}`;\n const midi = e.note.number;\n this._flash();\n this.dispatchEvent(new CustomEvent(\"noteoff\", {\n detail: {\n name,\n midi,\n velocity: e.velocity,\n },\n composed: true,\n bubbles: true,\n }));\n });\n input.addListener(\"controlchange\", \"all\", (e) => {\n this._flash();\n });\n }\n }\n static get styles() {\n return lit_element_1.css `\n\t\t\t:host {\n\t\t\t\tdisplay: block;\n\t\t\t}\n\n\t\t\t#container {\n\t\t\t\tdisplay: block;\n\t\t\t\tmargin-bottom: 10px;\n\t\t\t\tposition: relative;\n\t\t\t}\n\t\t\tlabel {\n\t\t\t\tfont-family: var(--label-font-family);\n\t\t\t\tfont-size: var(--label-font-size);\n\t\t\t\tmargin-right: 5px;\n\t\t\t\tfont-size: 0.7em;\n\t\t\t}\n\n\t\t\tselect,\n\t\t\tlabel {\n\t\t\t\tdisplay: inline-block;\n\t\t\t}\n\n\t\t\t#light {\n\t\t\t\twidth: 10px;\n\t\t\t\theight: 10px;\n\t\t\t\tbackground-color: white;\n\t\t\t\tdisplay: inline-block;\n\t\t\t}\n\t\t\t#light.connected {\n\t\t\t\tbackground-color: var(--color-gray);\n\t\t\t}\n\n\t\t\t#light.connected.flash {\n\t\t\t\tbackground-color: black !important;\n\t\t\t}\n\t\t`;\n }\n render() {\n if (WebMidi.supported) {\n return lit_element_1.html `\n\t\t\t\t<div id=\"container\">\n\t\t\t\t\t<div id=\"light\"></div>\n\t\t\t\t\t<label>MIDI IN:</label>\n\t\t\t\t\t<select @change=${this._connectMidi.bind(this)}>\n\t\t\t\t\t\t<option value=\"none\">none</option>\n\t\t\t\t\t\t${WebMidi.inputs.map((input) => lit_element_1.html `\n\t\t\t\t\t\t\t\t<option value=${input.id}>${input.name}</option>\n\t\t\t\t\t\t\t`)}\n\t\t\t\t\t</select>\n\t\t\t\t</div>\n\t\t\t`;\n }\n else {\n return lit_element_1.html ``;\n }\n }\n};\nToneMidiIn = __decorate([\n lit_element_1.customElement(\"tone-midi-in\")\n], ToneMidiIn);\nexports.ToneMidiIn = ToneMidiIn;\n\n\n//# sourceURL=webpack:///./src/gui/piano/midi-in.ts?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./src/gui/piano/note.ts":
|
|
/*!*******************************!*\
|
|
!*** ./src/gui/piano/note.ts ***!
|
|
\*******************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.ToneKeyboardNote = void 0;\nconst lit_element_1 = __webpack_require__(/*! lit-element */ \"./node_modules/lit-element/lit-element.js\");\nconst tone_1 = __webpack_require__(/*! tone */ \"tone\");\nlet ToneKeyboardNote = class ToneKeyboardNote extends lit_element_1.LitElement {\n constructor() {\n super(...arguments);\n this.color = \"#eee\";\n this.activecolor = \"white\";\n this.active = false;\n this.touchid = -1;\n }\n _fromMidi(midi) {\n return tone_1.Midi(midi).toNote();\n }\n updated(changed) {\n if (changed.has(\"active\") && changed.get(\"active\") !== undefined) {\n const eventName = this.active ? \"noteon\" : \"noteoff\";\n if (!this.active) {\n this.touchid = -1;\n }\n this.dispatchEvent(new CustomEvent(eventName, {\n detail: {\n name: this._fromMidi(this.note),\n midi: this.note,\n velocity: this.active ? 1 : 0,\n },\n composed: true,\n bubbles: true,\n }));\n }\n }\n _mouseover(e) {\n if (e.buttons) {\n this.active = true;\n this.shadowRoot.querySelector(\"button\").focus();\n }\n }\n _keydown(e) {\n if (!e.repeat && (e.key === \" \" || e.key === \"Enter\")) {\n this.active = true;\n }\n }\n _keyup(e) {\n if (e.key === \" \" || e.key === \"Enter\") {\n this.active = false;\n }\n }\n _touchstart(e) {\n e.preventDefault();\n this.touchid = e.touches[0].identifier;\n this.active = true;\n }\n static get styles() {\n return lit_element_1.css `\n\t\t\t:host {\n\t\t\t\tdisplay: block;\n\t\t\t}\n\n\t\t\t#container {\n\t\t\t\twidth: 100%;\n\t\t\t\theight: 100%;\n\t\t\t\tdisplay: block;\n\t\t\t}\n\t\t\t#container:not([show]) {\n\t\t\t\topacity: 0;\n\t\t\t\tmargin: 2px;\n\t\t\t\tpointer-events: none;\n\t\t\t}\n\n\t\t\tbutton {\n\t\t\t\tborder: none;\n\t\t\t\t-webkit-appearance: none;\n\t\t\t\t--key-margin: 2px;\n\t\t\t\twidth: 100%;\n\t\t\t\theight: 100%;\n\t\t\t\tborder: 2px solid white;\n\t\t\t\tbox-sizing: border-box;\n\t\t\t\tpadding: 0;\n\t\t\t\toutline: none;\n\t\t\t\ttransition: background-color 0.2s;\n\t\t\t\tcolor: transparent;\n\t\t\t\tfont-size: 0px;\n\t\t\t\tborder-radius: 2px;\n\t\t\t}\n\t\t\tbutton[active] {\n\t\t\t\tbackground-color: #666 !important;\n\t\t\t\ttransition-duration: 0s;\n\t\t\t}\n\t\t\tbutton:focus {\n\t\t\t\tborder-color: #666;\n\t\t\t}\n\t\t`;\n }\n render() {\n const show = this.note !== 0;\n return lit_element_1.html `\n\t\t\t<div id=\"container\" ?show=${show}>\n\t\t\t\t${show\n ? lit_element_1.html ` <button\n\t\t\t\t\t\t\t?active=${this.active}\n\t\t\t\t\t\t\t@mouseover=${this._mouseover.bind(this)}\n\t\t\t\t\t\t\t@mouseleave=${() => (this.active = false)}\n\t\t\t\t\t\t\t@mousedown=${() => (this.active = true)}\n\t\t\t\t\t\t\t@touchstart=${this._touchstart.bind(this)}\n\t\t\t\t\t\t\t@touchend=${() => (this.active = false)}\n\t\t\t\t\t\t\t@mouseup=${() => (this.active = false)}\n\t\t\t\t\t\t\t@keydown=${this._keydown.bind(this)}\n\t\t\t\t\t\t\t@keyup=${this._keyup.bind(this)}\n\t\t\t\t\t\t\tstyle=\"background-color: ${this.active\n ? this.activecolor\n : this.color};\"\n\t\t\t\t\t >\n\t\t\t\t\t\t\t${this._fromMidi(this.note).replace(\"#\", \"♯\")}\n\t\t\t\t\t </button>`\n : lit_element_1.html ``}\n\t\t\t</div>\n\t\t`;\n }\n};\n__decorate([\n lit_element_1.property({ type: Number })\n], ToneKeyboardNote.prototype, \"note\", void 0);\n__decorate([\n lit_element_1.property({ type: String })\n], ToneKeyboardNote.prototype, \"color\", void 0);\n__decorate([\n lit_element_1.property({ type: String })\n], ToneKeyboardNote.prototype, \"activecolor\", void 0);\n__decorate([\n lit_element_1.property({ type: Boolean })\n], ToneKeyboardNote.prototype, \"active\", void 0);\n__decorate([\n lit_element_1.property({ type: Number })\n], ToneKeyboardNote.prototype, \"velocity\", void 0);\n__decorate([\n lit_element_1.property({ type: Number })\n], ToneKeyboardNote.prototype, \"touchid\", void 0);\nToneKeyboardNote = __decorate([\n lit_element_1.customElement(\"tone-keyboard-note\")\n], ToneKeyboardNote);\nexports.ToneKeyboardNote = ToneKeyboardNote;\n\n\n//# sourceURL=webpack:///./src/gui/piano/note.ts?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./src/gui/piano/octave.ts":
|
|
/*!*********************************!*\
|
|
!*** ./src/gui/piano/octave.ts ***!
|
|
\*********************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.ToneKeyboardOctave = void 0;\nconst lit_element_1 = __webpack_require__(/*! lit-element */ \"./node_modules/lit-element/lit-element.js\");\nlet ToneKeyboardOctave = class ToneKeyboardOctave extends lit_element_1.LitElement {\n constructor() {\n super(...arguments);\n this.octave = 1;\n }\n noteon(number) {\n const note = this.shadowRoot.querySelector(`tone-keyboard-note[note=\"${number}\"]`);\n note.active = true;\n }\n noteoff(number) {\n const note = this.shadowRoot.querySelector(`tone-keyboard-note[note=\"${number}\"]`);\n note.active = false;\n }\n getNoteByTouchId(id) {\n const notes = Array.from(this.shadowRoot.querySelectorAll(\"tone-keyboard-note\"));\n const element = notes.find((e) => e.touchid === id);\n if (element && element.note) {\n return element;\n }\n }\n static get styles() {\n return lit_element_1.css `\n\t\t\t#container {\n\t\t\t\tdisplay: block;\n\t\t\t\tposition: relative;\n\t\t\t\theight: 100%;\n\t\t\t\twidth: 100%;\n\t\t\t}\n\t\t\ttone-keyboard-note {\n\t\t\t\torder: 0;\n\t\t\t\tflex-grow: 1;\n\t\t\t}\n\n\t\t\t#white-notes {\n\t\t\t\tposition: absolute;\n\t\t\t\tleft: 0px;\n\t\t\t\ttop: 0px;\n\t\t\t\twidth: 100%;\n\t\t\t\theight: 100%;\n\t\t\t\tdisplay: flex;\n\t\t\t\tflex-direction: row;\n\t\t\t}\n\n\t\t\t#black-notes {\n\t\t\t\tposition: absolute;\n\t\t\t\ttop: 0px;\n\t\t\t\twidth: 100%;\n\t\t\t\tdisplay: flex;\n\t\t\t\tflex-direction: row;\n\t\t\t\theight: 55%;\n\t\t\t}\n\n\t\t\t#black-notes tone-keyboard-note:first-child,\n\t\t\t#black-notes tone-keyboard-note:last-child {\n\t\t\t\tflex-grow: 0.5;\n\t\t\t\tpointer-events: none;\n\t\t\t}\n\t\t`;\n }\n render() {\n const startNote = 12 * this.octave;\n const whiteNotes = [0, 2, 4, 5, 7, 9, 11].map((i) => i + startNote);\n const blackNotes = [0, 1, 3, 0, 6, 8, 10, 0].map((i) => {\n if (i) {\n return i + startNote;\n }\n else {\n return 0;\n }\n });\n return lit_element_1.html `\n\t\t\t<div id=\"container\">\n\t\t\t\t<div id=\"white-notes\">\n\t\t\t\t\t${whiteNotes.map((note) => lit_element_1.html `\n\t\t\t\t\t\t\t<tone-keyboard-note\n\t\t\t\t\t\t\t\tcolor=\"#aaa\"\n\t\t\t\t\t\t\t\tnote=\"${note.toString()}\"\n\t\t\t\t\t\t\t></tone-keyboard-note>\n\t\t\t\t\t\t`)}\n\t\t\t\t</div>\n\t\t\t\t<div id=\"black-notes\">\n\t\t\t\t\t${blackNotes.map((note) => lit_element_1.html `\n\t\t\t\t\t\t\t<tone-keyboard-note\n\t\t\t\t\t\t\t\tcolor=\"black\"\n\t\t\t\t\t\t\t\tnote=\"${note.toString()}\"\n\t\t\t\t\t\t\t></tone-keyboard-note>\n\t\t\t\t\t\t`)}\n\t\t\t\t</div>\n\t\t\t</div>\n\t\t`;\n }\n};\n__decorate([\n lit_element_1.property({ type: Number })\n], ToneKeyboardOctave.prototype, \"octave\", void 0);\nToneKeyboardOctave = __decorate([\n lit_element_1.customElement(\"tone-keyboard-octave\")\n], ToneKeyboardOctave);\nexports.ToneKeyboardOctave = ToneKeyboardOctave;\n\n\n//# sourceURL=webpack:///./src/gui/piano/octave.ts?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./src/gui/piano/piano.ts":
|
|
/*!********************************!*\
|
|
!*** ./src/gui/piano/piano.ts ***!
|
|
\********************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.createPiano = exports.TonePiano = void 0;\nconst lit_element_1 = __webpack_require__(/*! lit-element */ \"./node_modules/lit-element/lit-element.js\");\n__webpack_require__(/*! ./keyboard */ \"./src/gui/piano/keyboard.ts\");\n__webpack_require__(/*! ./midi-in */ \"./src/gui/piano/midi-in.ts\");\nlet TonePiano = class TonePiano extends lit_element_1.LitElement {\n constructor() {\n super(...arguments);\n this.polyphonic = false;\n }\n firstUpdated(props) {\n super.firstUpdated(props);\n const keyboard = this.shadowRoot.querySelector(\"tone-keyboard\");\n // this.shadowRoot.querySelector(\"tone-midi-in\").addEventListener(\"noteon\", e => {\n // \te.stopPropagation();\n // \tkeyboard.noteon(e.detail.midi);\n // });\n // this.shadowRoot.querySelector(\"tone-midi-in\").addEventListener(\"noteoff\", e => {\n // \te.stopPropagation();\n // \tkeyboard.noteoff(e.detail.midi);\n // });\n window.addEventListener(\"resize\", this._resize.bind(this));\n setTimeout(() => this._resize(), 100);\n }\n _clamp(v, floor, ceil) {\n return Math.max(Math.min(v, ceil), floor);\n }\n _scale(v, inMin, inMax, outMin, outMax) {\n return ((v - inMin) / (inMax - inMin)) * (outMax - outMin) + outMin;\n }\n _resize() {\n const width = this.shadowRoot.querySelector(\"#container\").clientWidth;\n const octaves = this._clamp(Math.floor(width / 100) - 1, 1, 8);\n const rootNote = Math.ceil(this._scale(octaves, 1, 8, 5, 1));\n this.shadowRoot.querySelector(\"tone-keyboard\").rootoctave = rootNote;\n this.shadowRoot.querySelector(\"tone-keyboard\").octaves = octaves;\n }\n render() {\n return lit_element_1.html `\n\t\t\t<style>\n\t\t\t\t:host {\n\t\t\t\t\tdisplay: block;\n\t\t\t\t}\n\n\t\t\t\t#container {\n\t\t\t\t\tbackground-color: var(--color-light-gray);\n\t\t\t\t\tposition: relative;\n\t\t\t\t\tpadding: 5px;\n\t\t\t\t\tdisplay: block;\n\t\t\t\t}\n\n\t\t\t\ttone-keyboard {\n\t\t\t\t\tdisplay: block;\n\t\t\t\t\tclear: both;\n\t\t\t\t}\n\n\t\t\t\ttone-midi-in {\n\t\t\t\t\tposition: relative;\n\t\t\t\t\ttop: 5px;\n\t\t\t\t\tright: 5px;\n\t\t\t\t\tdisplay: inline-block;\n\t\t\t\t\tfloat: right;\n\t\t\t\t}\n\t\t\t</style>\n\t\t\t<div id=\"container\">\n\t\t\t\t<tone-midi-in> </tone-midi-in>\n\t\t\t\t<tone-keyboard ?polyphonic=${this.polyphonic}></tone-keyboard>\n\t\t\t</div>\n\t\t`;\n }\n};\n__decorate([\n lit_element_1.property({ type: Boolean })\n], TonePiano.prototype, \"polyphonic\", void 0);\nTonePiano = __decorate([\n lit_element_1.customElement(\"tone-piano\")\n], TonePiano);\nexports.TonePiano = TonePiano;\n/**\n * Create an audio node element\n */\nfunction createPiano({ parent, polyphonic = true, noteon = () => { }, noteoff = () => { }, }) {\n const element = document.createElement(\"tone-piano\");\n element.polyphonic = polyphonic;\n element.addEventListener(\"noteon\", (e) => noteon(e.detail));\n element.addEventListener(\"noteoff\", (e) => noteoff(e.detail));\n if (parent) {\n parent.appendChild(element);\n }\n return element;\n}\nexports.createPiano = createPiano;\n\n\n//# sourceURL=webpack:///./src/gui/piano/piano.ts?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./src/gui/value/array.ts":
|
|
/*!********************************!*\
|
|
!*** ./src/gui/value/array.ts ***!
|
|
\********************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.ToneArrayValue = void 0;\nconst lit_element_1 = __webpack_require__(/*! lit-element */ \"./node_modules/lit-element/lit-element.js\");\nconst value_1 = __webpack_require__(/*! ./value */ \"./src/gui/value/value.ts\");\nconst style_map_1 = __webpack_require__(/*! lit-html/directives/style-map */ \"./node_modules/lit-html/directives/style-map.js\");\nlet ToneArrayValue = class ToneArrayValue extends value_1.ToneValue {\n constructor() {\n super(...arguments);\n this.value = [];\n }\n reset() {\n // do nothing\n }\n scale(v, inMin, inMax, outMin, outMax) {\n const normV = Math.pow((v - inMin) / (inMax - inMin), 0.25);\n return normV * (outMax - outMin) + outMin;\n }\n _mousemove(index, e) {\n if (e.buttons) {\n let normValue = e.offsetY / e.target.clientHeight;\n normValue = Math.min(Math.max(normValue, 0), 1);\n this.value[index] = Math.pow(1 - normValue, 1 / 0.25);\n this.dispatchValue(this.value);\n this.requestUpdate();\n }\n }\n render() {\n const values = this.value.map(Math.abs);\n const min = Math.min(...values, 0);\n const max = Math.max(...values, 1);\n return lit_element_1.html `\n\t\t\t<div id=\"container\" class=\"array\">\n\t\t\t\t<label ?disabled=${values.length === 0}>${this.name}</label>\n\t\t\t\t<span id=\"bars\">\n\t\t\t\t\t${values.map((v, i) => lit_element_1.html `\n\t\t\t\t\t\t\t<span\n\t\t\t\t\t\t\t\tclass=\"bar\"\n\t\t\t\t\t\t\t\t@mousedown=${(e) => this._mousemove(i, e)}\n\t\t\t\t\t\t\t\t@mousemove=${(e) => this._mousemove(i, e)}\n\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t<span\n\t\t\t\t\t\t\t\t\tstyle=${style_map_1.styleMap({\n height: `${this.scale(v, min, max, 0, 100)}%`,\n })}\n\t\t\t\t\t\t\t\t\tclass=\"fill\"\n\t\t\t\t\t\t\t\t></span>\n\t\t\t\t\t\t\t</span>\n\t\t\t\t\t\t`)}\n\t\t\t\t</span>\n\t\t\t</div>\n\t\t`;\n }\n};\n__decorate([\n lit_element_1.property({ type: String })\n], ToneArrayValue.prototype, \"name\", void 0);\n__decorate([\n lit_element_1.property({ type: Array })\n], ToneArrayValue.prototype, \"value\", void 0);\nToneArrayValue = __decorate([\n lit_element_1.customElement(\"tone-array\")\n], ToneArrayValue);\nexports.ToneArrayValue = ToneArrayValue;\n\n\n//# sourceURL=webpack:///./src/gui/value/array.ts?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./src/gui/value/boolean.ts":
|
|
/*!**********************************!*\
|
|
!*** ./src/gui/value/boolean.ts ***!
|
|
\**********************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.ToneBooleanValue = void 0;\nconst lit_element_1 = __webpack_require__(/*! lit-element */ \"./node_modules/lit-element/lit-element.js\");\nconst value_1 = __webpack_require__(/*! ./value */ \"./src/gui/value/value.ts\");\nlet ToneBooleanValue = class ToneBooleanValue extends value_1.ToneValue {\n constructor() {\n super(...arguments);\n this.value = false;\n }\n _oninput(e) {\n e.stopPropagation();\n this.value = this.inputEl.checked;\n this.dispatchValue(this.value);\n }\n reset() {\n this.inputEl.checked = this.value;\n }\n render() {\n return lit_element_1.html `\n\t\t\t<div id=\"container\" class=\"boolean\">\n\t\t\t\t<label for=\"check\">${this.name}</label>\n\t\t\t\t<input\n\t\t\t\t\t@input=${this._oninput.bind(this)}\n\t\t\t\t\tname=\"check\"\n\t\t\t\t\ttype=\"checkbox\"\n\t\t\t\t\t?checked=${this.value}\n\t\t\t\t/>\n\t\t\t</div>\n\t\t`;\n }\n};\n__decorate([\n lit_element_1.query(\"input\")\n], ToneBooleanValue.prototype, \"inputEl\", void 0);\n__decorate([\n lit_element_1.property({ type: String })\n], ToneBooleanValue.prototype, \"name\", void 0);\n__decorate([\n lit_element_1.property({ type: Boolean })\n], ToneBooleanValue.prototype, \"value\", void 0);\nToneBooleanValue = __decorate([\n lit_element_1.customElement(\"tone-boolean\")\n], ToneBooleanValue);\nexports.ToneBooleanValue = ToneBooleanValue;\n\n\n//# sourceURL=webpack:///./src/gui/value/boolean.ts?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./src/gui/value/number.ts":
|
|
/*!*********************************!*\
|
|
!*** ./src/gui/value/number.ts ***!
|
|
\*********************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.ToneNumberValue = void 0;\nconst lit_element_1 = __webpack_require__(/*! lit-element */ \"./node_modules/lit-element/lit-element.js\");\nconst value_1 = __webpack_require__(/*! ./value */ \"./src/gui/value/value.ts\");\nlet ToneNumberValue = class ToneNumberValue extends value_1.ToneValue {\n constructor() {\n super(...arguments);\n this.value = 0;\n this.alt = false;\n this.shift = false;\n this.dragging = false;\n }\n firstUpdated(changed) {\n super.firstUpdated(changed);\n window.addEventListener(\"mousemove\", (e) => {\n if (this.dragging) {\n e.preventDefault();\n // find the relative change\n const box = this.shadowRoot.host.getBoundingClientRect();\n const yDiff = box.top + (box.bottom - box.top) / 2 - e.clientY;\n const multiplier = this.shift\n ? this.alt\n ? 0.01\n : 10\n : this.alt\n ? 0.1\n : 1;\n this.value =\n this.dragstartValue + Math.floor(yDiff / 10) * multiplier;\n this.dispatchValue(this.value);\n }\n });\n window.addEventListener(\"keydown\", (e) => {\n if (e.keyCode === 18) {\n this.alt = true;\n }\n this.shift = e.shiftKey;\n });\n window.addEventListener(\"keyup\", (e) => {\n if (e.keyCode === 18) {\n this.alt = false;\n }\n this.shift = e.shiftKey;\n });\n }\n _oninput(e) {\n e.preventDefault();\n e.stopPropagation();\n const value = parseFloat(this.shadowRoot.querySelector(\"input\").value);\n if (isFinite(value)) {\n this.value = value;\n this.dispatchValue(value);\n }\n }\n _onkeypress(e) {\n let modified = false;\n if (e.key === \"ArrowUp\") {\n modified = true;\n if (this.shift) {\n this.value += this.alt ? 0.01 : 10;\n }\n else {\n this.value += this.alt ? 0.1 : 1;\n }\n }\n else if (e.key === \"ArrowDown\") {\n modified = true;\n if (this.shift) {\n this.value -= this.alt ? 0.01 : 10;\n }\n else {\n this.value -= this.alt ? 0.1 : 1;\n }\n }\n if (modified) {\n e.preventDefault();\n this.dispatchValue(this.value);\n }\n }\n reset() {\n this.shadowRoot.querySelector(\"input\").value = this.beautifyValue(this.value).toString();\n }\n _dragstart(e) {\n this.dragging = true;\n this.dragstartValue = this.value;\n window.addEventListener(\"mouseup\", () => {\n if (this.dragstartValue !== this.value) {\n this.dispatchValue(this.value);\n }\n this.dragging = false;\n }, { once: true });\n }\n beautifyValue(val) {\n const float = val.toString().split(\".\")[1];\n return parseFloat(val.toFixed(Math.min(float && float.length, 4)));\n }\n render() {\n return lit_element_1.html `\n\t\t\t<div id=\"container\">\n\t\t\t\t<label for=\"number\">${this.name}</label>\n\t\t\t\t<input\n\t\t\t\t\t@mousedown=${this._dragstart.bind(this)}\n\t\t\t\t\t@keydown=${this._onkeypress.bind(this)}\n\t\t\t\t\t@change=${this._oninput.bind(this)}\n\t\t\t\t\tname=\"number\"\n\t\t\t\t\ttype=\"text\"\n\t\t\t\t\t.value=\"${this.beautifyValue(this.value)}\"\n\t\t\t\t/>\n\t\t\t</div>\n\t\t`;\n }\n};\n__decorate([\n lit_element_1.property({ type: String })\n], ToneNumberValue.prototype, \"name\", void 0);\n__decorate([\n lit_element_1.property({ type: Number })\n], ToneNumberValue.prototype, \"value\", void 0);\nToneNumberValue = __decorate([\n lit_element_1.customElement(\"tone-number\")\n], ToneNumberValue);\nexports.ToneNumberValue = ToneNumberValue;\n\n\n//# sourceURL=webpack:///./src/gui/value/number.ts?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./src/gui/value/string.ts":
|
|
/*!*********************************!*\
|
|
!*** ./src/gui/value/string.ts ***!
|
|
\*********************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.ToneStringValue = void 0;\nconst lit_element_1 = __webpack_require__(/*! lit-element */ \"./node_modules/lit-element/lit-element.js\");\nconst value_1 = __webpack_require__(/*! ./value */ \"./src/gui/value/value.ts\");\nlet ToneStringValue = class ToneStringValue extends value_1.ToneValue {\n constructor() {\n super(...arguments);\n this.value = \"\";\n }\n _oninput(e) {\n e.stopPropagation();\n e.stopImmediatePropagation();\n this.value = this.inputEl.value;\n this.dispatchValue(this.value);\n }\n reset() {\n this.inputEl.value = this.value;\n }\n render() {\n return lit_element_1.html `\n\t\t\t<div id=\"container\">\n\t\t\t\t<label for=\"string\">${this.name}</label>\n\t\t\t\t<input\n\t\t\t\t\t@input=${(e) => e.stopPropagation()}\n\t\t\t\t\t@change=${this._oninput.bind(this)}\n\t\t\t\t\tname=\"string\"\n\t\t\t\t\ttype=\"text\"\n\t\t\t\t\t.value=${this.value}\n\t\t\t\t/>\n\t\t\t</div>\n\t\t`;\n }\n};\n__decorate([\n lit_element_1.property({ type: String })\n], ToneStringValue.prototype, \"name\", void 0);\n__decorate([\n lit_element_1.property({ type: String })\n], ToneStringValue.prototype, \"value\", void 0);\n__decorate([\n lit_element_1.query(\"input\")\n], ToneStringValue.prototype, \"inputEl\", void 0);\nToneStringValue = __decorate([\n lit_element_1.customElement(\"tone-string\")\n], ToneStringValue);\nexports.ToneStringValue = ToneStringValue;\n\n\n//# sourceURL=webpack:///./src/gui/value/string.ts?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./src/gui/value/value.scss":
|
|
/*!**********************************!*\
|
|
!*** ./src/gui/value/value.scss ***!
|
|
\**********************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
eval("\n var result = __webpack_require__(/*! !../../../node_modules/css-loader/dist/cjs.js!../../../node_modules/sass-loader/dist/cjs.js??ref--5-2!./value.scss */ \"./node_modules/css-loader/dist/cjs.js!./node_modules/sass-loader/dist/cjs.js?!./src/gui/value/value.scss\");\n\n if (typeof result === \"string\") {\n module.exports = result;\n } else {\n module.exports = result.toString();\n }\n \n\n//# sourceURL=webpack:///./src/gui/value/value.scss?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./src/gui/value/value.ts":
|
|
/*!********************************!*\
|
|
!*** ./src/gui/value/value.ts ***!
|
|
\********************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.ToneValue = void 0;\nconst lit_element_1 = __webpack_require__(/*! lit-element */ \"./node_modules/lit-element/lit-element.js\");\n// eslint-disable-next-line @typescript-eslint/no-var-requires\nconst style = __webpack_require__(/*! ./value.scss */ \"./src/gui/value/value.scss\");\n/**\n * Base class for values\n */\nclass ToneValue extends lit_element_1.LitElement {\n /**\n * Beautify the value before it's set\n */\n beautifyValue(val) {\n return val;\n }\n /**\n * Trigger a \"value\" event. Value events have a rejected callback\n * in case the value is not valid\n */\n dispatchValue(value) {\n this.dispatchEvent(new CustomEvent(\"value\", {\n detail: {\n value,\n reject: (val) => {\n this.value = val;\n // flash red quickly?\n this.shadowRoot\n .querySelector(\"#container\")\n .classList.add(\"error\");\n setTimeout(() => {\n this.shadowRoot\n .querySelector(\"#container\")\n .classList.remove(\"error\");\n }, 100);\n this.reset();\n },\n },\n }));\n }\n static get styles() {\n return lit_element_1.css `\n\t\t\t${lit_element_1.unsafeCSS(style)}\n\t\t`;\n }\n render() {\n return lit_element_1.html ` ${this.name} `;\n }\n}\n__decorate([\n lit_element_1.property({ type: String })\n], ToneValue.prototype, \"name\", void 0);\nexports.ToneValue = ToneValue;\n\n\n//# sourceURL=webpack:///./src/gui/value/value.ts?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./src/gui/vis/buffer.ts":
|
|
/*!*******************************!*\
|
|
!*** ./src/gui/vis/buffer.ts ***!
|
|
\*******************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.ToneBufferViz = void 0;\nconst lit_element_1 = __webpack_require__(/*! lit-element */ \"./node_modules/lit-element/lit-element.js\");\nconst vis_base_1 = __webpack_require__(/*! ./vis-base */ \"./src/gui/vis/vis-base.ts\");\nlet ToneBufferViz = class ToneBufferViz extends vis_base_1.VisBase {\n generate() {\n return __awaiter(this, void 0, void 0, function* () {\n if (!this.tone) {\n return;\n }\n if (!this.tone.buffer.loaded) {\n yield new Promise((done) => (this.tone.buffer.onload = done));\n }\n const values = this.tone.buffer.getChannelData(0);\n this.draw(values);\n });\n }\n bind(tone) {\n this.tone = tone;\n this.generate();\n }\n};\nToneBufferViz = __decorate([\n lit_element_1.customElement(\"tone-buffer-vis\")\n], ToneBufferViz);\nexports.ToneBufferViz = ToneBufferViz;\n\n\n//# sourceURL=webpack:///./src/gui/vis/buffer.ts?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./src/gui/vis/compressor.ts":
|
|
/*!***********************************!*\
|
|
!*** ./src/gui/vis/compressor.ts ***!
|
|
\***********************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.ToneCompressorVis = void 0;\nconst lit_element_1 = __webpack_require__(/*! lit-element */ \"./node_modules/lit-element/lit-element.js\");\nconst vis_base_1 = __webpack_require__(/*! ./vis-base */ \"./src/gui/vis/vis-base.ts\");\nlet ToneCompressorVis = class ToneCompressorVis extends vis_base_1.VisBase {\n constructor() {\n super(...arguments);\n this.normalizeCurve = false;\n }\n generate() {\n return __awaiter(this, void 0, void 0, function* () {\n if (!this.tone) {\n return;\n }\n const length = this.width;\n const kneeWidth = this.scale(this.tone.knee.value, 0, 100, 0, length);\n const threshIndex = this.scale(this.tone.threshold.value, -100, 40, 0, length);\n const retArray = new Float32Array(length);\n const ratio = this.tone.ratio.value;\n const kneeBegin = threshIndex - kneeWidth / 2;\n const kneeEnd = threshIndex + kneeWidth / 2;\n const kneeBeginNorm = this.scale(kneeBegin, 0, length, 0, 1);\n const threshNorm = this.scale(threshIndex, 0, length, 0, 1);\n const values = retArray.map((_, i) => {\n const linearVal = this.scale(i, 0, length, 0, 1);\n // apply the ratio\n if (i < kneeBegin) {\n // linear\n return linearVal;\n }\n else if (kneeBegin <= i && i <= kneeEnd) {\n // in the knee\n const over = this.scale(kneeEnd - threshIndex, 0, length, 0, 1);\n const compressedValue = threshNorm + over * (1 / ratio);\n return this.scale(i, kneeBegin, kneeEnd, kneeBeginNorm, compressedValue);\n }\n else {\n // compressing\n const over = this.scale(i - threshIndex, 0, length, 0, 1);\n const compressedValue = threshNorm + over * (1 / ratio);\n return compressedValue;\n }\n });\n this.draw(values);\n });\n }\n draw(values) {\n // draw the values\n super.draw(values);\n const canvas = this.shadowRoot.querySelector(\"canvas\");\n const context = canvas.getContext(\"2d\");\n context.setLineDash([2, 2]);\n context.lineWidth = 1;\n context.strokeStyle = \"rgba(0, 0, 0, 0.25)\";\n // draw the thresh and knee lines\n const threshX = this.scale(this.tone.threshold.value, -100, 40, 0, canvas.width);\n const threshY = this.scale(this.tone.threshold.value, -100, 40, canvas.height, 0);\n context.moveTo(threshX, 0);\n context.lineTo(threshX, canvas.height);\n context.stroke();\n context.moveTo(0, threshY);\n context.lineTo(canvas.width, threshY);\n context.stroke();\n context.setLineDash([]);\n }\n bind(tone) {\n this.tone = tone;\n this.generate();\n this.loop();\n }\n loop() {\n requestAnimationFrame(this.loop.bind(this));\n // check the reduction\n const reduction = this.scale(this.tone.reduction, 0, -100, 0, 100);\n this.shadowRoot.querySelector(\"#reduction #fill\").style.height = `${reduction.toFixed(1)}%`;\n }\n render() {\n return lit_element_1.html `\n\t\t\t<style>\n\t\t\t\t#container {\n\t\t\t\t\tmargin-top: 5px;\n\t\t\t\t\tposition: relative;\n\t\t\t\t}\n\n\t\t\t\tcanvas {\n\t\t\t\t\twidth: calc(100% - 50px);\n\t\t\t\t\theight: ${this.height}px;\n\t\t\t\t}\n\n\t\t\t\t#reduction {\n\t\t\t\t\tposition: absolute;\n\t\t\t\t\twidth: 20px;\n\t\t\t\t\theight: ${this.height}px;\n\t\t\t\t\tright: 0px;\n\t\t\t\t\ttop: 0px;\n\t\t\t\t}\n\n\t\t\t\t#reduction #fill {\n\t\t\t\t\tbackground-color: black;\n\t\t\t\t\twidth: 100%;\n\t\t\t\t\theight: 0%;\n\t\t\t\t\ttop: 0px;\n\t\t\t\t\tleft: 0px;\n\t\t\t\t}\n\t\t\t</style>\n\t\t\t<div id=\"container\">\n\t\t\t\t<canvas></canvas>\n\t\t\t\t<div id=\"reduction\">\n\t\t\t\t\t<div id=\"fill\"></div>\n\t\t\t\t</div>\n\t\t\t</div>\n\t\t`;\n }\n};\nToneCompressorVis = __decorate([\n lit_element_1.customElement(\"tone-compressor-vis\")\n], ToneCompressorVis);\nexports.ToneCompressorVis = ToneCompressorVis;\n\n\n//# sourceURL=webpack:///./src/gui/vis/compressor.ts?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./src/gui/vis/envelope.ts":
|
|
/*!*********************************!*\
|
|
!*** ./src/gui/vis/envelope.ts ***!
|
|
\*********************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.ToneEnvelopeVis = void 0;\nconst vis_base_1 = __webpack_require__(/*! ./vis-base */ \"./src/gui/vis/vis-base.ts\");\nconst lit_element_1 = __webpack_require__(/*! lit-element */ \"./node_modules/lit-element/lit-element.js\");\nconst style_map_1 = __webpack_require__(/*! lit-html/directives/style-map */ \"./node_modules/lit-html/directives/style-map.js\");\nlet ToneEnvelopeVis = class ToneEnvelopeVis extends vis_base_1.VisBase {\n generate() {\n return __awaiter(this, void 0, void 0, function* () {\n if (!this.tone) {\n return;\n }\n const values = yield this.tone.asArray(this.width);\n this.draw(values);\n this.requestUpdate();\n });\n }\n bind(tone) {\n this.tone = tone;\n this.generate();\n }\n render() {\n const times = [];\n if (this.tone) {\n const tickCount = 4;\n // add the timing to the bottom\n const totalDuration = 1.1 *\n (this.tone.toSeconds(this.tone.attack) +\n this.tone.toSeconds(this.tone.decay) +\n this.tone.toSeconds(this.tone.release));\n // scoot the canvas up 10px\n // context.drawImage(canvas, 0, 0, this.width, this.height - 10);\n const subdivision = Math.pow(2, Math.ceil(Math.log2(totalDuration / tickCount)));\n const rounding = (subdivision.toString().split(\".\")[1] &&\n subdivision.toString().split(\".\")[1].length) ||\n 0;\n for (let time = 0; time < totalDuration * 0.9; time += subdivision) {\n const x = time / totalDuration;\n times.push({\n x,\n time: time.toFixed(rounding),\n });\n }\n }\n return lit_element_1.html `\n\t\t\t<style>\n\t\t\t\t#timeline {\n\t\t\t\t\tmargin-top: -10px;\n\t\t\t\t\tfont-size: 10px;\n\t\t\t\t\tfont-family: monospace;\n\t\t\t\t\tposition: relative;\n\t\t\t\t\theight: 20px;\n\t\t\t\t}\n\t\t\t\t#timeline span {\n\t\t\t\t\tposition: absolute;\n\t\t\t\t}\n\t\t\t</style>\n\t\t\t${super.render()}\n\t\t\t<div id=\"timeline\">\n\t\t\t\t${times.map(({ x, time }) => lit_element_1.html `\n\t\t\t\t\t\t<span\n\t\t\t\t\t\t\tstyle=${style_map_1.styleMap({\n left: `${(x * 100).toFixed(2)}%`,\n })}\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t${time}s\n\t\t\t\t\t\t</span>\n\t\t\t\t\t`)}\n\t\t\t</div>\n\t\t`;\n }\n};\nToneEnvelopeVis = __decorate([\n lit_element_1.customElement(\"tone-envelope-vis\")\n], ToneEnvelopeVis);\nexports.ToneEnvelopeVis = ToneEnvelopeVis;\n\n\n//# sourceURL=webpack:///./src/gui/vis/envelope.ts?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./src/gui/vis/fft.ts":
|
|
/*!****************************!*\
|
|
!*** ./src/gui/vis/fft.ts ***!
|
|
\****************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.createFFT = void 0;\nconst vis_base_1 = __webpack_require__(/*! ./vis-base */ \"./src/gui/vis/vis-base.ts\");\nconst lit_element_1 = __webpack_require__(/*! lit-element */ \"./node_modules/lit-element/lit-element.js\");\nlet ToneFFTElement = class ToneFFTElement extends vis_base_1.VisBase {\n constructor() {\n super(...arguments);\n this.height = 40;\n }\n generate() {\n // ignored\n }\n loop() {\n requestAnimationFrame(this.loop.bind(this));\n if (!this.tone) {\n return;\n }\n const values = this.tone.getValue();\n this.draw(values);\n }\n bind(tone) {\n this.tone = tone;\n this.loop();\n }\n};\nToneFFTElement = __decorate([\n lit_element_1.customElement(\"tone-fft-vis\")\n], ToneFFTElement);\n/**\n * Create an audio node element\n */\nfunction createFFT({ tone, parent, height, }) {\n const element = document.createElement(\"tone-fft-vis\");\n element.bind(tone);\n if (parent) {\n parent.appendChild(element);\n }\n if (height) {\n element.setAttribute(\"height\", height.toString());\n }\n return element;\n}\nexports.createFFT = createFFT;\n\n\n//# sourceURL=webpack:///./src/gui/vis/fft.ts?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./src/gui/vis/filter.ts":
|
|
/*!*******************************!*\
|
|
!*** ./src/gui/vis/filter.ts ***!
|
|
\*******************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.ToneFFTVis = void 0;\nconst vis_base_1 = __webpack_require__(/*! ./vis-base */ \"./src/gui/vis/vis-base.ts\");\nconst lit_element_1 = __webpack_require__(/*! lit-element */ \"./node_modules/lit-element/lit-element.js\");\nlet ToneFFTVis = class ToneFFTVis extends vis_base_1.VisBase {\n generate() {\n if (!this.tone) {\n return;\n }\n const values = this.tone.getFrequencyResponse(this.width);\n this.draw(values);\n }\n bind(tone) {\n this.tone = tone;\n this.generate();\n }\n};\nToneFFTVis = __decorate([\n lit_element_1.customElement(\"tone-filter-vis\")\n], ToneFFTVis);\nexports.ToneFFTVis = ToneFFTVis;\n\n\n//# sourceURL=webpack:///./src/gui/vis/filter.ts?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./src/gui/vis/meter.ts":
|
|
/*!******************************!*\
|
|
!*** ./src/gui/vis/meter.ts ***!
|
|
\******************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.createMeter = exports.ToneMeterElement = void 0;\nconst vis_base_1 = __webpack_require__(/*! ./vis-base */ \"./src/gui/vis/vis-base.ts\");\nconst lit_element_1 = __webpack_require__(/*! lit-element */ \"./node_modules/lit-element/lit-element.js\");\nconst Color = __webpack_require__(/*! color */ \"./node_modules/color/index.js\");\nconst style_map_1 = __webpack_require__(/*! lit-html/directives/style-map */ \"./node_modules/lit-html/directives/style-map.js\");\nlet ToneMeterElement = class ToneMeterElement extends vis_base_1.VisBase {\n constructor() {\n super(...arguments);\n this.height = 40;\n this.meterLevels = [];\n }\n generate() {\n // ignored\n }\n loop() {\n requestAnimationFrame(this.loop.bind(this));\n if (!this.tone) {\n return;\n }\n const values = this.tone.getValue();\n this.meterLevels = Array.isArray(values) ? values : [values];\n this.requestUpdate();\n }\n bind(tone) {\n this.tone = tone;\n this.tone.normalRange = true;\n this.loop();\n }\n renderColor(val) {\n return Color(\"#aaa\")\n .mix(Color(\"rgb(209, 196, 15)\"), Math.pow(val, 0.5))\n .hex();\n }\n render() {\n return lit_element_1.html `\n\t\t\t<style>\n\t\t\t\t#container {\n\t\t\t\t\tdisplay: flex;\n\t\t\t\t\talign-items: flex-end;\n\t\t\t\t\tborder: 2px outset #ddd;\n\t\t\t\t\tborder-color: transparent transparent #ddd;\n\t\t\t\t}\n\t\t\t\t.level {\n\t\t\t\t\tflex: 1;\n\t\t\t\t\tbackground-color: #aaa;\n\t\t\t\t\tmargin: 2px;\n\t\t\t\t\tmin-height: 2px;\n\t\t\t\t\tborder-top-left-radius: 2px;\n\t\t\t\t\tborder-top-right-radius: 2px;\n\t\t\t\t}\n\t\t\t</style>\n\t\t\t<div\n\t\t\t\tid=\"container\"\n\t\t\t\tstyle=${style_map_1.styleMap({\n height: `${this.height}px`,\n })}\n\t\t\t>\n\t\t\t\t${this.meterLevels.map((val) => lit_element_1.html `\n\t\t\t\t\t\t<div\n\t\t\t\t\t\t\tclass=\"level\"\n\t\t\t\t\t\t\tstyle=${style_map_1.styleMap({\n height: `${(Math.pow(val, 0.2) * 100).toFixed(2)}%`,\n backgroundColor: this.renderColor(val),\n })}\n\t\t\t\t\t\t></div>\n\t\t\t\t\t`)}\n\t\t\t</div>\n\t\t`;\n }\n};\nToneMeterElement = __decorate([\n lit_element_1.customElement(\"tone-meter-vis\")\n], ToneMeterElement);\nexports.ToneMeterElement = ToneMeterElement;\n/**\n * Create an audio node element\n */\nfunction createMeter({ tone, parent, height, }) {\n const element = document.createElement(\"tone-meter-vis\");\n element.bind(tone);\n if (parent) {\n parent.appendChild(element);\n }\n if (height) {\n element.setAttribute(\"height\", height.toString());\n }\n return element;\n}\nexports.createMeter = createMeter;\n\n\n//# sourceURL=webpack:///./src/gui/vis/meter.ts?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./src/gui/vis/oscillator.ts":
|
|
/*!***********************************!*\
|
|
!*** ./src/gui/vis/oscillator.ts ***!
|
|
\***********************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.ToneOscillatorVis = void 0;\nconst lit_element_1 = __webpack_require__(/*! lit-element */ \"./node_modules/lit-element/lit-element.js\");\nconst vis_base_1 = __webpack_require__(/*! ./vis-base */ \"./src/gui/vis/vis-base.ts\");\nlet ToneOscillatorVis = class ToneOscillatorVis extends vis_base_1.VisBase {\n generate() {\n return __awaiter(this, void 0, void 0, function* () {\n if (!this.tone) {\n return;\n }\n const values = yield this.tone.asArray(600);\n this.draw(values);\n });\n }\n bind(tone) {\n this.tone = tone;\n this.generate();\n }\n};\nToneOscillatorVis = __decorate([\n lit_element_1.customElement(\"tone-oscillator-vis\")\n], ToneOscillatorVis);\nexports.ToneOscillatorVis = ToneOscillatorVis;\n\n\n//# sourceURL=webpack:///./src/gui/vis/oscillator.ts?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./src/gui/vis/vis-base.ts":
|
|
/*!*********************************!*\
|
|
!*** ./src/gui/vis/vis-base.ts ***!
|
|
\*********************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.VisBase = void 0;\nconst lit_element_1 = __webpack_require__(/*! lit-element */ \"./node_modules/lit-element/lit-element.js\");\nclass VisBase extends lit_element_1.LitElement {\n constructor() {\n super(...arguments);\n this.bgcolor = \"white\";\n this.color = \"black\";\n this.values = {};\n this.height = 100;\n this.width = 310;\n this.normalizeCurve = true;\n }\n scale(v, inMin, inMax, outMin, outMax) {\n return ((v - inMin) / (inMax - inMin)) * (outMax - outMin) + outMin;\n }\n draw(values) {\n const canvas = this.shadowRoot.querySelector(\"canvas\");\n if (canvas) {\n const context = canvas.getContext(\"2d\");\n canvas.height = this.height;\n canvas.width = this.width;\n const width = canvas.width;\n const height = canvas.height;\n context.clearRect(0, 0, width, height);\n const maxValuesLength = 2048;\n if (values.length > maxValuesLength) {\n const resampled = new Float32Array(maxValuesLength);\n // down sample to maxValuesLength values\n for (let i = 0; i < maxValuesLength; i++) {\n resampled[i] =\n values[Math.floor((i / maxValuesLength) * values.length)];\n }\n values = resampled;\n }\n const max = this.normalizeCurve\n ? Math.max(0.001, ...values) * 1.1\n : 1;\n const min = this.normalizeCurve\n ? Math.min(-0.001, ...values) * 1.1\n : 0;\n const lineWidth = 3;\n context.lineWidth = lineWidth;\n context.beginPath();\n for (let i = 0; i < values.length; i++) {\n const v = values[i];\n const x = this.scale(i, 0, values.length, lineWidth, width - lineWidth);\n const y = this.scale(v, max, min, 0, height - lineWidth);\n if (i === 0) {\n context.moveTo(x, y);\n }\n else {\n context.lineTo(x, y);\n }\n }\n context.lineCap = \"round\";\n context.strokeStyle = \"white\";\n context.stroke();\n }\n }\n updated() {\n clearTimeout(this.timeout);\n this.timeout = setTimeout(() => {\n this.generate();\n }, 50);\n }\n render() {\n return lit_element_1.html `\n\t\t\t<style>\n\t\t\t\t#container {\n\t\t\t\t\tmargin-top: 5px;\n\t\t\t\t}\n\n\t\t\t\tcanvas {\n\t\t\t\t\tbackground-color: #aaa;\n\t\t\t\t\twidth: 100%;\n\t\t\t\t\tborder-radius: 4px;\n\t\t\t\t\theight: ${this.height}px;\n\t\t\t\t}\n\t\t\t</style>\n\t\t\t<div id=\"container\">\n\t\t\t\t<canvas></canvas>\n\t\t\t</div>\n\t\t`;\n }\n}\n__decorate([\n lit_element_1.property({ type: String })\n], VisBase.prototype, \"bgcolor\", void 0);\n__decorate([\n lit_element_1.property({ type: String })\n], VisBase.prototype, \"color\", void 0);\n__decorate([\n lit_element_1.property({ type: Object })\n], VisBase.prototype, \"values\", void 0);\n__decorate([\n lit_element_1.property({ type: Number })\n], VisBase.prototype, \"height\", void 0);\n__decorate([\n lit_element_1.property({ type: Number })\n], VisBase.prototype, \"width\", void 0);\nexports.VisBase = VisBase;\n\n\n//# sourceURL=webpack:///./src/gui/vis/vis-base.ts?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./src/gui/vis/visualizer.ts":
|
|
/*!***********************************!*\
|
|
!*** ./src/gui/vis/visualizer.ts ***!
|
|
\***********************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.ToneVisualizer = void 0;\nconst lit_element_1 = __webpack_require__(/*! lit-element */ \"./node_modules/lit-element/lit-element.js\");\nconst deepEquals = __webpack_require__(/*! deep-equal */ \"./node_modules/deep-equal/index.js\");\n__webpack_require__(/*! ./oscillator */ \"./src/gui/vis/oscillator.ts\");\n__webpack_require__(/*! ./envelope */ \"./src/gui/vis/envelope.ts\");\n__webpack_require__(/*! ./filter */ \"./src/gui/vis/filter.ts\");\n__webpack_require__(/*! ./compressor */ \"./src/gui/vis/compressor.ts\");\n__webpack_require__(/*! ./meter */ \"./src/gui/vis/meter.ts\");\n__webpack_require__(/*! ./waveform */ \"./src/gui/vis/waveform.ts\");\n__webpack_require__(/*! ./buffer */ \"./src/gui/vis/buffer.ts\");\nlet ToneVisualizer = class ToneVisualizer extends lit_element_1.LitElement {\n constructor() {\n super(...arguments);\n /**\n * Make sure that it is rendered for the first time\n * before applying shouldUpdate optimization\n */\n this.firstRendered = false;\n }\n bind(tone) {\n return __awaiter(this, void 0, void 0, function* () {\n // find the sub object\n this.tone = tone;\n this.path.forEach((path) => {\n this.tone = tone[path];\n });\n if (this.tone) {\n yield this.requestUpdate();\n this.shadowRoot\n .querySelectorAll(\".vis\")\n .forEach((vis) => {\n vis.bind(this.tone);\n });\n this.firstRendered = true;\n }\n });\n }\n shouldUpdate() {\n if (this.tone && this.firstRendered) {\n return deepEquals(this.values, this.tone.get());\n }\n else {\n return true;\n }\n }\n chooseVis() {\n if (this.tone.toString().includes(\"Envelope\")) {\n return lit_element_1.html `\n\t\t\t\t<tone-envelope-vis\n\t\t\t\t\tclass=\"vis\"\n\t\t\t\t\tvalues=${JSON.stringify(this.values)}\n\t\t\t\t></tone-envelope-vis>\n\t\t\t`;\n }\n else if (this.tone.toString().includes(\"Oscillator\")) {\n return lit_element_1.html `\n\t\t\t\t<tone-oscillator-vis\n\t\t\t\t\tclass=\"vis\"\n\t\t\t\t\tvalues=${JSON.stringify(this.values)}\n\t\t\t\t></tone-oscillator-vis>\n\t\t\t`;\n }\n else if (this.tone.toString() === \"Compressor\") {\n return lit_element_1.html `\n\t\t\t\t<tone-compressor-vis\n\t\t\t\t\tclass=\"vis\"\n\t\t\t\t\tvalues=${JSON.stringify(this.values)}\n\t\t\t\t></tone-compressor-vis>\n\t\t\t`;\n }\n else if (this.tone.toString() === \"Filter\" ||\n this.tone.toString() === \"OnePoleFilter\") {\n return lit_element_1.html `\n\t\t\t\t<tone-filter-vis\n\t\t\t\t\tclass=\"vis\"\n\t\t\t\t\tvalues=${JSON.stringify(this.values)}\n\t\t\t\t></tone-filter-vis>\n\t\t\t`;\n }\n else if (this.tone.toString() === \"Meter\") {\n return lit_element_1.html `\n\t\t\t\t<tone-meter-vis\n\t\t\t\t\tclass=\"vis\"\n\t\t\t\t\tvalues=${JSON.stringify(this.values)}\n\t\t\t\t></tone-meter-vis>\n\t\t\t`;\n }\n else if (this.tone.toString() === \"Waveform\") {\n return lit_element_1.html `\n\t\t\t\t<tone-waveform-vis\n\t\t\t\t\tclass=\"vis\"\n\t\t\t\t\tvalues=${JSON.stringify(this.values)}\n\t\t\t\t></tone-waveform-vis>\n\t\t\t`;\n }\n else if (this.tone.toString() === \"FFT\") {\n return lit_element_1.html `\n\t\t\t\t<tone-fft-vis\n\t\t\t\t\tclass=\"vis\"\n\t\t\t\t\tvalues=${JSON.stringify(this.values)}\n\t\t\t\t></tone-fft-vis>\n\t\t\t`;\n }\n else if (Reflect.has(this.tone, \"buffer\")) {\n return lit_element_1.html `\n\t\t\t\t<tone-buffer-vis\n\t\t\t\t\tclass=\"vis\"\n\t\t\t\t\tvalues=${JSON.stringify(this.values)}\n\t\t\t\t></tone-buffer-vis>\n\t\t\t`;\n }\n }\n render() {\n if (this.tone) {\n return lit_element_1.html `\n\t\t\t\t<div id=\"container\">\n\t\t\t\t\t${this.chooseVis()}\n\t\t\t\t</div>\n\t\t\t`;\n }\n }\n};\n__decorate([\n lit_element_1.property({ type: Array })\n], ToneVisualizer.prototype, \"path\", void 0);\n__decorate([\n lit_element_1.property({ type: Object })\n], ToneVisualizer.prototype, \"values\", void 0);\nToneVisualizer = __decorate([\n lit_element_1.customElement(\"tone-visualizer\")\n], ToneVisualizer);\nexports.ToneVisualizer = ToneVisualizer;\n\n\n//# sourceURL=webpack:///./src/gui/vis/visualizer.ts?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "./src/gui/vis/waveform.ts":
|
|
/*!*********************************!*\
|
|
!*** ./src/gui/vis/waveform.ts ***!
|
|
\*********************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
eval("\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.createWaveform = void 0;\nconst vis_base_1 = __webpack_require__(/*! ./vis-base */ \"./src/gui/vis/vis-base.ts\");\nconst lit_element_1 = __webpack_require__(/*! lit-element */ \"./node_modules/lit-element/lit-element.js\");\nlet ToneWaveformElement = class ToneWaveformElement extends vis_base_1.VisBase {\n constructor() {\n super(...arguments);\n this.height = 40;\n }\n generate() {\n // ignored\n }\n loop() {\n requestAnimationFrame(this.loop.bind(this));\n if (!this.tone) {\n return;\n }\n const values = this.tone.getValue();\n this.draw(values);\n }\n bind(tone) {\n this.tone = tone;\n this.loop();\n }\n};\nToneWaveformElement = __decorate([\n lit_element_1.customElement(\"tone-waveform-vis\")\n], ToneWaveformElement);\n/**\n * Create an audio node element\n */\nfunction createWaveform({ tone, parent, height, }) {\n const element = document.createElement(\"tone-waveform-vis\");\n element.bind(tone);\n if (parent) {\n parent.appendChild(element);\n }\n if (height) {\n element.setAttribute(\"height\", height.toString());\n }\n return element;\n}\nexports.createWaveform = createWaveform;\n\n\n//# sourceURL=webpack:///./src/gui/vis/waveform.ts?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ 0:
|
|
/*!********************************!*\
|
|
!*** ./util.inspect (ignored) ***!
|
|
\********************************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports) {
|
|
|
|
eval("/* (ignored) */\n\n//# sourceURL=webpack:///./util.inspect_(ignored)?");
|
|
|
|
/***/ }),
|
|
|
|
/***/ "tone":
|
|
/*!***********************!*\
|
|
!*** external "Tone" ***!
|
|
\***********************/
|
|
/*! no static exports found */
|
|
/***/ (function(module, exports) {
|
|
|
|
eval("module.exports = __WEBPACK_EXTERNAL_MODULE_tone__;\n\n//# sourceURL=webpack:///external_%22Tone%22?");
|
|
|
|
/***/ })
|
|
|
|
/******/ });
|
|
}); |